if(;){} opinion

Georg Wrede georg.wrede at nospam.org
Mon Feb 27 18:25:29 PST 2006


Derek Parnell wrote:
> On Mon, 27 Feb 2006 17:14:28 -0500, Carlos Santander wrote:
> 
> 
>> Derek Parnell escribió:
>> 
>>> On Mon, 27 Feb 2006 22:25:37 +1100, Nils Hensel
>>> <nils.hensel at web.de> wrote:
>>> 
>>> 
>>>> Lionello Lunesu schrieb:
>>>> 
>>>>> Talking of which: when is that "auto" ambiguity going to be
>>>>> resolved? (I still prefer "var" to "auto"
>>>> 
>>>> This would get my vote as well. "var" is far more intuitive and
>>>> it would be similar to DScript. I don't think there's an
>>>> obvious connection between "auto" and the data type of a
>>>> variable.
>>>> 
>>> 
>>> Thanks! There has been something bugging me about this since it
>>> appeared and that is it. True its an 'auto' but an auto what?
>>> Auto scope? Auto Type? Auto mobile? Auto initialization? Simply,
>>> 'auto' is way too ambiguous. At least 'var' is more focused.
>>> 
>>> --Derek Parnell Melbourne, Australia
>> 
>> I prefer auto for auto typing rather than for auto destruction.
>> Preferences...
> 
> 
> But that's my point ... 'auto' by itself is ambiguous and for a
> first-timer to understand it depends somewhat on one's preconceptions
> and preferences.

I agree.

auto for types is barely bearable. But something better should be 
invented. Personally I'd even settle for "var", in the worst case.

auto for RAII is not even barely bearable. We could even use "raii" 
rather than "auto". At least it wouldn't be ambiguous or opaque.



More information about the Digitalmars-d mailing list