Martin Panter added the comment:

For what it’s worth, every now and then I have to stop and remember that I 
can’t do this sort of thing:

unsupported_keys = config_dict.keys().difference(supported_list)

though it is not a big problem to rewrite it as

unsupported_keys = config_dict.keys() - set(supported_list)

Also it looks like one can already effectively do x.copy() using the existing 
immutable Set operators, so that worm can is already opened:

>>> ListBasedSet("abc") & ListBasedSet("abc")
<__main__.ListBasedSet object at 0x7f419951b860>

On the other hand, a matching almost equivalent operator does exist for 
a.issubset(b): a <= b, or a.__le__(b).

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue23161>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to