Fixing D's Properties
Sean Kelly
sean at f4.ca
Fri Aug 17 14:18:59 PDT 2007
Bill Baxter wrote:
> Sean Kelly wrote:
>
>> Otherwise I see little reason to change "inout" to "ref."
>
> I thought the reason was more to do with const. Given a const object
> passed by reference, calling it 'inout' doesn't make much sense.
This is the explanation I remember as well. But I'm not sure it
justifies the addition of a general-purpose sounding keyword simply for
parameter passing. "inout" may have been a bit confusing in light of
const reference passing, but is consistency with "in" and "out" made it
arguably worth retaining.
Sean
More information about the Digitalmars-d
mailing list