forked from swiftlang/swift
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AST: Change TypeAliasDecls to store an interface type as their underl…
…ying type - TypeAliasDecl::getAliasType() is gone. Now, getDeclaredInterfaceType() always returns the NameAliasType. - NameAliasTypes now always desugar to the underlying type as an interface type. - The NameAliasType of a generic type alias no longer desugars to an UnboundGenericType; call TypeAliasDecl::getUnboundGenericType() if you want that. - The "lazy mapTypeOutOfContext()" hack for deserialized TypeAliasDecls is gone. - The process of constructing a synthesized TypeAliasDecl is much simpler now; instead of calling computeType(), setInterfaceType() and then setting the recursive properties in the right order, just call setUnderlyingType(), passing it either an interface type or a contextual type. In particular, many places weren't setting the recursive properties, such as the ClangImporter and deserialization. This meant that queries such as hasArchetype() or hasTypeParameter() would return incorrect results on NameAliasTypes, which caused various subtle problems. - Finally, add some more tests for generic typealiases, most of which fail because they're still pretty broken.
- Loading branch information
1 parent
757f253
commit 2c6b9f7
Showing
39 changed files
with
392 additions
and
285 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
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
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
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
Oops, something went wrong.