The point of const, scope, and other attributes

IGotD- nise at nise.com
Wed May 11 10:48:20 UTC 2022


On Wednesday, 11 May 2022 at 07:21:02 UTC, Dukc wrote:
>
> I am increasingly of the opinion that DIP1000 is too 
> complicated for the average programmer to understand well. I 
> find myself often stratching my head with it, it would be 
> overwhelming for a beginner.
>

C# went the other way, no const parameters at all. Maybe because 
it doesn't make much sense because there is a lot of runtime 
violations of const underneath. Anyway, I like the C# aproach 
better because it is simpler for the programmer.

Another problem is that all this badging tend to get out of hand 
and it breeds more badges until it doesn't mean anything. For 
example what will happen if D adds a mutable attribute?


More information about the Digitalmars-d mailing list