New semantic analyzer: regression with circular import and TypeVar #7037
Labels
bug
mypy got something wrong
false-positive
mypy gave an error on correct code
priority-0-high
semantic-analyzer
Problems that happen during semantic analysis
topic-import-cycles
I found a regression when using the new semantic analyzer in mypy 0.710.
To reproduce, you need the following two modules:
When mypy is run on these modules with the default arguments, no issues are reported. But when run withthe new semantic analyzer, the following happens:
The problem does not occur if there is no circular import. It also doesn't occur if the
BoxT
TypeVar is defined in thefactory
module instead of imported from thebox
module.The text was updated successfully, but these errors were encountered: