[swift-evolution] [Review] SE-0025 Scoped Access Level
Joseph Lord
joseph at human-friendly.com
Fri Feb 26 19:52:56 CST 2016
The key differences are:
1) You are already the file implementing on that area of code if you are in the same file.
2) The file shouldn't be that big whereas the module is likely to have hundreds of files and several people on it.
3) There are performance benefits to be had with private (at least when Whole Module Optimisation is off).
I'm not too worried if it does get included it just seems the gains will be quite small. Can you point me to some code that would really benefit or where the lack of it has caused mistakes or problems in the past?
Joseph
> On Feb 27, 2016, at 1:24 AM, Ilya Belenkiy <ilya.belenkiy at gmail.com> wrote:
>
> By the same logic, the comment alone is enough, the private keyword isn't necessary. The benefit of scoped is that the intent would be enforceable by the compiler.
>> On Fri, Feb 26, 2016 at 6:48 PM Joseph Lord via swift-evolution <swift-evolution at swift.org> wrote:
>>> On Feb 26, 2016, at 7:05 PM, Douglas Gregor via swift-evolution <swift-evolution at swift.org> wrote:
>>>
>>> The review of SE-0025 “Scoped Access Level" begins now and runs through March 3, 2016. The proposal is available here:
>>>
>>> https://github.com/apple/swift-evolution/blob/master/proposals/0025-scoped-access-level.md
>>
>> -0.1
>> There is nothing wrong with this proposal but I just don't see the value over private (plus a little doc comment if absolutely necessary).
>>
>> Downside is more language to learn / encounter and complexity to maintain.
>>
>> I've read the proposal but not the preceding discussion.
>>
>> Joseph
>> _______________________________________________
>> 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/20160227/b7fdbbb0/attachment.html>
More information about the swift-evolution
mailing list