[swift-evolution] Enhancing access levels without breaking changes

Matthew Johnson matthew at anandabits.com
Mon Apr 10 10:30:03 CDT 2017

> On Apr 10, 2017, at 10:26 AM, Tino Heth via swift-evolution <swift-evolution at swift.org> wrote:
>> I’m not sure that this solves anything meaningful (whether in relation to SE-0169 or more generally), does it? What advantage does this provide over just declaring the protocol conformance and those methods as a direct part of the parent type? This seems like it would just introduce more indentation, and more lines of code, for zero benefit.
> Well, I'm not overwhelmingly convinced of this whole "we put same-module stuff into extensions" anyways, so it's debatable wether proposals like SE-0169 have any meaningful effects at all… do you think that conformances in same-file extensions have a real benefit? 

I think the primary benefit is organizational.  People like having the members that implement a conformance grouped together with the conformance declaration.

> If nothing else, nested extensions could save those who actually don't care much about such issues from another breaking change in Swift — and imho it adds consistency:
> We can nest types, so why can't we nest extensions?
> _______________________________________________
> swift-evolution mailing list
> swift-evolution at swift.org
> https://lists.swift.org/mailman/listinfo/swift-evolution

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20170410/baea760d/attachment.html>

More information about the swift-evolution mailing list