Using classmethod
of generic alias of a generic type and --disallow-any-generics
#16982
Labels
topic-inference
When to infer types or require explicit annotations
topic-type-alias
TypeAlias and other type alias issues
Code:
Link: https://mypy-play.net/?mypy=latest&python=3.12&flags=disallow-any-generics&gist=f657946226b54d0654952c6bcdb02a61
Problem: I think that
[type-arg]
error should not be raised in this case, because no type param is actually needed in this case.classmethod
is often used as a constructor, duplicating type vars is verbose and unneeded.The text was updated successfully, but these errors were encountered: