[issue7771] dict view comparison methods are not documented

Raymond Hettinger report at bugs.python.org
Sat Oct 9 00:34:28 CEST 2010


Raymond Hettinger <rhettinger at users.sourceforge.net> added the comment:

The '^' corresponds to the __xor__ magic method.

snip from _abcoll.py:

    def __xor__(self, other):
        if not isinstance(other, Set):
            if not isinstance(other, Iterable):
                return NotImplemented
            other = self._from_iterable(other)
        return (self - other) | (other - self)

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue7771>
_______________________________________


More information about the Python-bugs-list mailing list