[swift-evolution] Will Swift ever support optional methods without @objc?
Chris Lattner
clattner at apple.com
Tue Nov 15 16:13:48 CST 2016
> On Nov 14, 2016, at 3:48 PM, Rick Mann via swift-evolution <swift-evolution at swift.org> wrote:
>
> Will Swift ever support optional methods without @objc?
>
We discussed this extensively in the Swift 3 timeframe, and I believe that the consensus was “no”: optional requirements are considered an Objective-C compatibility feature.
I don’t recall all of the discussion, but a major one would have to be that it is highly redundant with other language features we already have, and makes the design space of Swift APIs more complicated. If Objective-C didn’t already have them, we would never consider adding them to our protocol model.
-Chris
More information about the swift-evolution
mailing list