Serhiy Storchaka added the comment: dict.pop() supports unhashable values, but dict.__contains__() and dict.get() don't:
>>> [] in {} Traceback (most recent call last): File "<stdin>", line 1, in <module> TypeError: unhashable type: 'list' >>> {}.get([], 42) Traceback (most recent call last): File "<stdin>", line 1, in <module> TypeError: unhashable type: 'list' >>> {}.pop([], 42) 42 OrderedDict.pop() also doesn't support unhashable values: >>> collections.OrderedDict().pop([], 42) Traceback (most recent call last): File "<stdin>", line 1, in <module> TypeError: unhashable type: 'list' ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue30100> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com