Closed
Description
Previous ID | SR-4637 |
Radar | None |
Original Reporter | garricn (JIRA User) |
Type | Bug |
Status | Resolved |
Resolution | Done |
Attachment: Download
Environment
Xcode 8.3.1, Swift 3.1
Additional Detail from JIRA
Votes | 2 |
Component/s | Compiler |
Labels | Bug, StarterBug |
Assignee | ismetanin (JIRA) |
Priority | Medium |
md5: ea3ce9103e3b95d06baa97059732e723
Issue Description:
As of SR-2444, optional closures as function parameters are already escaping escaping by default. Currently, when adding the @escaping attribute to an optional closure parameter, the compiler throws the following error:
@escaping attribute only applies to function types
Since this type is already escaping escaping by default, it would be helpful to add / amend the error as follows:
Optional closures are already @escaping.
And add the following Fix-it:
Fix-it Delete "@escaping"