-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Closed
Labels
tyMulti-file analysis & type inferenceMulti-file analysis & type inference
Milestone
Description
Currently we have Definitions for function parameters (that is, inside the function body we know that those names are defined), but we only infer @Todo types for those names, even if the parameter has a type annotation.
The tricky part of implementing this inference correctly is that we have to handle PEP 695 generic type parameter scopes, e.g. def f[T](x: T): ... has a special implicit scope in between the containing scope and the function's body scope, in which T is defined. So for generic functions we have to do inference of the parameter type annotations in that scope, not in the outer scope.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
tyMulti-file analysis & type inferenceMulti-file analysis & type inference