`restricted` member variables

bauss jj_1337 at live.dk
Tue Jun 21 12:18:35 UTC 2022


On Tuesday, 21 June 2022 at 11:23:36 UTC, Ola Fosheim Grøstad 
wrote:
> On Tuesday, 21 June 2022 at 11:06:17 UTC, bauss wrote:
>> D will do anything to not have class private.
>
> Yes, but you can do it with @UDA + linter.
>
> That is a much better approach than getting more complexity 
> into the language (anything more complex than a «hidden» 
> specifier should be rejected)

I don't agree that it's a better approach because then you also 
have to use a linter and can't just resort to using the compiler.

Unless D shipped with a linter that worked with every editor 
and/or could be put into your build system easily, then I don't 
think it's a better solution.

I'd much rather have the compiler yield an error to me and then 
fix that, than relying on yet another third party tool.


More information about the Digitalmars-d mailing list