Const spec status.

Bruno Medeiros brunodomedeiros+spam at com.gmail
Tue Apr 29 04:25:47 PDT 2008


Janice Caron wrote:
> 2008/4/29 Bruno Medeiros <brunodomedeiros+spam at com.gmail>:
>>  Hum, I feel a bit silly, I originally thought that *all* cases would be an
>> error, so maybe it was just I that got confused with a previous version of
>> const. (where values could only be assigned to variables with the same
>> "head-constness", which is not the case here)
> 
> The definition of const hasn't changed. (At least, not recently). It's
> just that bugs have been fixed. The compiler is now better at figuring
> out what is safe and what is not.
> 

I had the impression that this code:
   invariant a = 2;
   int b = a;
was at some point either not working, or written in the doc as not 
working. But that doesn't matter anymore, I agree what we have now is 
good (at least the basic semantics) , so let's move on. :)

-- 
Bruno Medeiros - Software Developer, MSc. in CS/E graduate
http://www.prowiki.org/wiki4d/wiki.cgi?BrunoMedeiros#D



More information about the Digitalmars-d mailing list