We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
From the Python documentation it is clear that using TypeVar(... bound=Example) will constraint the type to a subclass of Example.
TypeVar(... bound=Example)
Example
What is unclear is how:
_U = TypeVar('_U', bound=Example) Type[_U]
Is different from:
Type[Example]
Is there any reason to prefer one over the other? and what are the consequences of these differences?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
From the Python documentation it is clear that using
TypeVar(... bound=Example)
will constraint the type to a subclass ofExample
.What is unclear is how:
Is different from:
Is there any reason to prefer one over the other? and what are the consequences of these differences?
The text was updated successfully, but these errors were encountered: