Message323297
If you have a class that defines __new__ to the __new__ of another builtin type that it isn't a subclass of:
>>> class X:
... __new__ = tuple.__new__
Instantiating this class should produce an error because `tuple.__new__` can't handle non-tuples, but instead it succeeds:
>>> X()
<__main__.X object at 0x00000000032C3F98>
(related: issue34284) |
|
Date |
User |
Action |
Args |
2018-08-08 19:07:33 | ppperry | set | recipients:
+ ppperry, ncoghlan, serhiy.storchaka, Vadim Pushtaev |
2018-08-08 19:07:33 | ppperry | set | messageid: <1533755253.45.0.56676864532.issue34362@psf.upfronthosting.co.za> |
2018-08-08 19:07:33 | ppperry | link | issue34362 messages |
2018-08-08 19:07:33 | ppperry | create | |
|