Adding a new design constraint to D

Max Samukha maxsamukha at gmail.com
Sun Jun 19 11:19:43 UTC 2022


On Sunday, 19 June 2022 at 09:46:40 UTC, Sergey wrote:
> On Sunday, 19 June 2022 at 08:12:28 UTC, forkit wrote:
>> On Saturday, 18 June 2022 at 05:50:56 UTC, Walter Bright wrote:
>>>
>> What is the rationale?
>
> Just leave it here, to be sure, that every participant of the 
> thread have seen this:
>
> https://dlang.org/blog/2018/11/06/lost-in-translation-encapsulation/

And the nonsensical debates like 
https://dlang.org/blog/2018/11/06/lost-in-translation-encapsulation/#comment-6546 wouldn't have happened, if D had done the most reasonable thing from the start - make 'private' mean 'private to the current scope'; provide 'private(ancestor)' for choosing the encapsulation boundary; and maybe provide shortcuts for module and package. That's it. No need for articles trying to justify the arbitrary imposition.


More information about the Digitalmars-d mailing list