Stepping back and looking at constness from another angle.
Craig Black
cblack at ara.com
Tue Jun 5 14:49:41 PDT 2007
Guess I should put in my 2 cents also, since there are so many people who
seem to dislike the idea of const in D. I am a C++ programmer that uses
const a lot. I am the primary author of a very big API that is used by
other developers.
There are cases where things get complicated, but for the most part, const
really helps. It helps that the compiler enforces the rules. So I like the
idea of adding const to D in some form. I admit I don't understand all the
details of D's const implementation, but I don't think that adding const in
D is a bad thing.
Walter said himself that the next release of D will be alpha, so changes can
be made if necessary. Therefore, I would consider the current approach to
const to be a first draft.
D's const implementation seems much more thought-out than C++'s.
Personally, I am excited to see what this feature will give us.
-Craig
More information about the Digitalmars-d
mailing list