-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[red-knot] Gradual forms do not participate in equivalence/subtyping (#…
…14758) ## Summary This changeset contains various improvements concerning non-fully-static types and their relationships: - Make sure that non-fully-static types do not participate in equivalence or subtyping. - Clarify what `Type::is_equivalent_to` actually implements. - Introduce `Type::is_fully_static` - New tests making sure that multiple `Any`/`Unknown`s inside unions and intersections are collapsed. closes #14524 ## Test Plan - Added new unit tests for union and intersection builder - Added new unit tests for `Type::is_equivalent_to` - Added new unit tests for `Type::is_subtype_of` - Added new property test making sure that non-fully-static types do not participate in subtyping
- Loading branch information
Showing
3 changed files
with
190 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters