Why D is not popular enough?

Chris Wright via Digitalmars-d digitalmars-d at puremagic.com
Sun Aug 14 09:15:23 PDT 2016


On Sun, 14 Aug 2016 08:18:08 +0300, Shachar Shemesh wrote:
> The first is that you can rarely put "const" on anything, meaning you
> lose the power that C++'s guarantee gave you, and not gain enough in
> return.

I can often put const on things. However, it's an added step, the 
compiler doesn't prompt me, and I can't add it everywhere. The result is 
that I make things const-correct about 2% of the time.

If function parameters were const by default, that would prompt me to try 
to make my code const-correct. If there were a module-level annotation I 
could use to turn on const-by-default, I would use it.


More information about the Digitalmars-d mailing list