Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #106623
| From | Antoon Pardon <antoon.pardon@rece.vub.ac.be> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | deque is not a subclass of Sequence. |
| Date | 2016-04-07 10:49 +0200 |
| Message-ID | <mailman.7.1460018974.2253.python-list@python.org> (permalink) |
| References | <57061F13.90100@rece.vub.ac.be> |
Playing around with the collections and collections.abc modules in python3.4 I stumbled upon the following: >>> from collections.abc import Sequence >>> from collections import deque >>> isinstance(list(), Sequence) True >>> isinstance(deque(), Sequence) False >>> This seems strange to me. As far as I understand, the documentation indicates there is no reason why deque shouldn't be a subclass of Sequence. Am I missing something or can this be considered a bug? -- Antoon.
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
deque is not a subclass of Sequence. Antoon Pardon <antoon.pardon@rece.vub.ac.be> - 2016-04-07 10:49 +0200
csiph-web