thoughts on immutability in D

Andrej Mitrovic andrej.mitrovich at gmail.com
Fri Sep 23 15:58:22 PDT 2011


On 9/24/11, Peter Alexander <peter.alexander.au at gmail.com> wrote:
> On 23/09/11 6:48 AM, Walter Bright wrote:
>> On 9/22/2011 4:39 AM, bearophile wrote:
>>> Walter:
>> "logical const" in C++ is faith-based programming.
>
> I think you're exaggerating it's uselessness.
>
> It's faith-based as much as 'walking down the street assuming that the
> next person won't stab you' is faith-based. There's no guarantee, but
> 99% of the time your "faith" is well placed.
>

So then don't use const if u need caching and use convention if your
faith is well placed!


More information about the Digitalmars-d mailing list