-
Notifications
You must be signed in to change notification settings - Fork 226
Closed
Labels
bidirectional inferenceInference of types that takes into account the context of a declared type or expected typeInference of types that takes into account the context of a declared type or expected typegenericsBugs or features relating to ty's generics implementationBugs or features relating to ty's generics implementation
Milestone
Description
Summary
Feel free to rename or mark as duplicate if there's a pre-existing issue that better describes the root cause. The closest related I found was maybe #1648 / #1576
Passing a list of literals to list or set loses type information with ty. Whereas both mypy and pyright keep the literal generic types:
- https://mypy-play.net/?gist=698f5d996f794a1a02536cebb8fe47a1
- https://play.ty.dev/7f70524b-6288-4669-8627-62926ed7bad5
- pyright playground
Version
ty 0.0.1-alpha.32
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bidirectional inferenceInference of types that takes into account the context of a declared type or expected typeInference of types that takes into account the context of a declared type or expected typegenericsBugs or features relating to ty's generics implementationBugs or features relating to ty's generics implementation