[issue46669] Add types.Self
Raymond Hettinger
report at bugs.python.org
Tue Feb 8 00:25:38 EST 2022
Raymond Hettinger <raymond.hettinger at gmail.com> added the comment:
> Your suggested signature looks like it's trying to support
> the second invariant, but it doesn't quite: if the types
> don't match, the type checker will just set T to the
> common base type of the two arguments.
Is there a way to write the second invariant correctly?
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue46669>
_______________________________________
More information about the Python-bugs-list
mailing list