[swift-evolution] [Proposal] Revising access modifiers on extensions
jordan_rose at apple.com
Sun Jun 26 19:41:22 CDT 2016
Hi, Adrian. Can you explain why you want to make this change? “public” on an extension doesn’t mean anything by itself because you can’t refer to an extension as an entity in and of itself. Access modifiers are disallowed on extensions with protocols because the conformance isn’t controlled by the access modifier and we didn’t want to give the impression that it would.
There’s really no such thing as an “implicitly public extension”. An extension is just a bag of additional members and conformances. An access modifier on the extension sets the default access level of members in the extension as a convenience.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the swift-evolution