[swift-evolution] [Review] SE-0159: Fix Private Access Levels

Xiaodi Wu xiaodi.wu at gmail.com
Sat Mar 25 00:00:59 CDT 2017

On Fri, Mar 24, 2017 at 11:55 PM, Carl Brown1 <Carl.Brown1 at ibm.com> wrote:

> Maybe this is the core of this whole issue. In my experience, the very
> easiest part of the software development process is getting it to compile.
> The *real effort* doesn't even start until after that's completed.
> If I thought that "case-sensitive find-and-relace" was "the tricky thing"
> in developing software, and all I had to care about was avoiding "invalid
> redeclarations anywhere" then this proposal might seem like a good idea to
> me, too.
My point is that, in rolling back the specific portion of SE-0025,
case-sensitive find-and-replace will be the trickiest thing in most
codebases, save those that result in invalid redeclarations. The behavior
of the resultant code is, unless I'm mistaken, provably unchanged. This in
itself bolsters the case that the distinction between `fileprivate` and
`private` did not really carry its own weight.

Indeed, if I thought that there would be an unknowable amount of effort
required to migrate code, then I would be more hesitant about rolling back
SE-0025. That said, I'm curious as to how your argument would not apply to
literally every single source-breaking change.

> -Carl
> [image: Inactive hide details for Xiaodi Wu via swift-evolution
> ---03/24/2017 11:10:54 PM---On Fri, Mar 24, 2017 at 10:47 PM, Xiaodi Wu]Xiaodi
> Wu via swift-evolution ---03/24/2017 11:10:54 PM---On Fri, Mar 24, 2017 at
> 10:47 PM, Xiaodi Wu <xiaodi.wu at gmail.com> wrote: > As Chris has said in
> the
> From: Xiaodi Wu via swift-evolution <swift-evolution at swift.org>
> To: Drew Crawford <drew at sealedabstract.com>, Jonathan Hull <jhull at gbis.com
> >
> Cc: swift-evolution <swift-evolution at swift.org>
> Date: 03/24/2017 11:10 PM
> Subject: Re: [swift-evolution] [Review] SE-0159: Fix Private Access Levels
> Sent by: swift-evolution-bounces at swift.org
> ------------------------------
> On Fri, Mar 24, 2017 at 10:47 PM, Xiaodi Wu <*xiaodi.wu at gmail.com*
> <xiaodi.wu at gmail.com>> wrote:
> Update: with the caveat that corelibs-foundation tests are incomplete, it
> took me about 15 mins to migrate all uses of private to fileprivate. The
> tricky thing is that one has to do case-sensitive find-and-replace, and to
> replace all instances of "filefileprivate" in a second round. It does not
> appear that corelibs-foundation actually uses new `private` in a way that
> migrating to `fileprivate` results in invalid redeclarations anywhere.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20170325/08f81b48/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: graycol.gif
Type: image/gif
Size: 105 bytes
Desc: not available
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20170325/08f81b48/attachment.gif>

More information about the swift-evolution mailing list