Dlang and POO

Mike Parker aldacron at gmail.com
Wed Jun 23 07:29:54 UTC 2021


On Wednesday, 23 June 2021 at 07:04:05 UTC, user1234 wrote:
> On Tuesday, 22 June 2021 at 02:37:28 UTC, user1234 wrote:
>> would require a new keyword
>
> I think actually that "super private" would work.

We already have the means to handle this for people who really 
really want it. Make the module a package and put all of the 
SuperSecretSauce ingredients in their own modules.

- mymodulepackage
-- package.d
-- opensecrets.d
-- supersecretsauce1.d
-- supersecretsauce2.d

Package protection lets you share whatever needs to be shared 
between each module, you are able to fully restrict access to 
private members, and clients are able to `import mymodulepackage` 
without worrying about the details.


More information about the Digitalmars-d mailing list