any news on const/invariant?

Derek Parnell derek at psych.ward
Thu Nov 29 01:45:48 PST 2007


On Thu, 29 Nov 2007 01:06:32 -0800, Walter Bright wrote:

> Derek Parnell wrote:
>> Is this supposed to compile? I can't get it to work. 
>> 
>> For the source line ...
>> 
>>   const(const(int*) f()){}
>> 
>> I get the message ...
>> 
>> test.d(3): unexpected identifer 'f' in declarator
>> test.d(3): no identifier for declarator const(int*)()
> 
> Uh, you're right. You can't put the identifier inside a declarator.

Yes, I know one can't, but I actually asked if one is supposed to able to
do it. 

Did you intend that "const(const(int*) f()){}" should compile, even though
currently it doesn't?

-- 
Derek Parnell
Melbourne, Australia
skype: derek.j.parnell



More information about the Digitalmars-d mailing list