This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author rhettinger
Recipients brandtbucher, mrabarnett, rhettinger, steven.daprano
Date 2021-01-31.17:48:19
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1612115299.44.0.90274067365.issue43085@roundup.psfhosted.org>
In-reply-to
Content
The operators | and |= always call __or__() and __ior__().  Support for these methods is optional.  Some mapping classes support both methods, some only support __or__, and some support neither one.

Adding support is done is done on a case by case basis.  SignalDict could be updated if needed.

To make it easier for user defined classes, two new collections.ABCs could be added, MappingWithOr and MutableMappingWithIor.  That is similar to what we had done in Python 2.7 with UserDict and IterableUserDict.
History
Date User Action Args
2021-01-31 17:48:19rhettingersetrecipients: + rhettinger, mrabarnett, steven.daprano, brandtbucher
2021-01-31 17:48:19rhettingersetmessageid: <1612115299.44.0.90274067365.issue43085@roundup.psfhosted.org>
2021-01-31 17:48:19rhettingerlinkissue43085 messages
2021-01-31 17:48:19rhettingercreate