[Python-ideas] issubclass(collections.OrderedDict, collections.Sequence)
Ram Rachum
ram at rachum.com
Sun Oct 5 20:40:47 CEST 2014
Hi guys,
I was just going to test whether a mapping is dict-like or an
OrderedDict-like object by doing this:
isinstance(x, collections.Sequence)
But then I checked and saw that this is False:
issubclass(collections.OrderedDict, collections.Sequence) is False
Why isn't an OrderedDict a Sequence?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20141005/0b0fba3d/attachment.html>
More information about the Python-ideas
mailing list