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.
Sema: Teach getReferencedAssociatedTypes() to look through typealiases
Now that NameAliasTypes desugar to interface types, it is possible to have a protocol requirement type contain a NameAliasType which contains an associated type: protocol P { associatedtype Element typealias Elements = [Element] func process(elements: Elements) } In Swift 3, the typealias would be desugared at name lookup time in this case, but this is no longer the case, as a result associated type inference stopped working in this example. Fixes <https://bugs.swift.org/browse/SR-3641>.
- Loading branch information
1 parent
b861853
commit 0926773
Showing
2 changed files
with
17 additions
and
8 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