You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm experiencing a similar issue in Xcode 10.2 beta, the following code doesn't compile:
public enum Outcome {
case A
case B
}
public protocol Runner {
typealias Completion = (Outcome) -> ()
func run<D>(input: D, completion: @escaping Completion)
}
It does compile if run function isn't generic though.
Environment
Swift 3 Xcode 8 b6
Additional Detail from JIRA
md5: 67bc4caa824a17d9c863a46912ed30bc
duplicates:
Issue Description:
Xcode b6:
That seems to assume already that the closures scapes the function, while without the typealias I have to write
I would like to write
but that triggers the error "@escaping attribute applies only to function types"
Also, I see this syntax is supported:
but it breaks quick lookup in Xcode (IMO @escaping shouldn't be allowed in typealias)
The text was updated successfully, but these errors were encountered: