bpo-44632: Fix support of TypeVar in the union type#27139
Conversation
int | TypeVar('T') returns now an instance of types.Union
instead of typing.Union.
b36ae20 to
531338f
Compare
Fidget-Spinner
left a comment
There was a problem hiding this comment.
LGTM. I was working on this too and I eventually came to the same solution as you :).
|
Hmm does this need news? Or are we bundling all the TypeVar issues into one news item later on? |
|
It has little effect on user. |
|
Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.10. |
|
GH-27143 is a backport of this pull request to the 3.10 branch. |
int | TypeVar('T') returns now an instance of types.Union
instead of typing.Union.
(cherry picked from commit a158b20)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
|
https://bugs.python.org/issue44632