ruff
64e7e1aa - [red-knot] Add `Type::TypeVar` variant (#17102)

Commit
175 days ago
[red-knot] Add `Type::TypeVar` variant (#17102) This adds a new `Type` variant for holding an instance of a typevar inside of a generic function or class. We don't handle specializing the typevars yet, but this should implement most of the typing rules for inside the generic function/class, where we don't know yet which specific type the typevar will be specialized to. This PR does _not_ yet handle the constraint that multiple occurrences of the typevar must be specialized to the _same_ time. (There is an existing test case for this in `generics/functions.md` which is still marked as TODO.) --------- Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com> Co-authored-by: Carl Meyer <carl@astral.sh>
Author
Parents
Loading