> Le 3 avr. 2017 à 16:20, John McCall via swift-evolution > <[email protected]> a écrit : > >> I hope the core team will reconsider the spelling change to “private” and >> “scoped”. > > We won't.
I find that unfortunate, but it's good to be fixed. I recently replaced every instance of `private` by `fileprivate` in my code. This discussion made me realize that the intended unit of encapsulation for me when I write `private` is almost always the file. The code should reflect that intent regardless of whether the compiler would allow a narrower access level to be used. I will reserve `private` for special occasions when tighter encapsulation is needed. Doing it that way, `private` will actually have some meaning when I use it. Current use is zero though, and that's fine by me. As for introducing type-based private, it'd probably make using `private` for special occasions less interesting because the additional protection over `fileprivate` are negligible. -- Michel Fortin https://michelf.ca _______________________________________________ swift-evolution mailing list [email protected] https://lists.swift.org/mailman/listinfo/swift-evolution
