Writing const-correct code in D

xs0 xs0 at xs0.com
Wed Mar 8 06:45:57 PST 2006


> I would like it this is how I have been using const in c++

Well, there are some differences from C++ const:

- from what I gather, const is shallow, not deep
- there is no mutability inference in C++
- there's no romaybe, so lots of code is written twice without any real 
need for it
- support for arrays is limited
- the name is much worse :)

See the paper for a longer discussion.


xs0



More information about the Digitalmars-d mailing list