properties - Why not the set/get syntax?

Kyle Furlong kylefurlong at gmail.com
Sun Apr 2 00:28:08 PST 2006


Derek Parnell wrote:
> On Sun, 02 Apr 2006 11:31:13 +1000, Jarrett Billingsley 
> <kb3ctd2 at yahoo.com> wrote:
> 
>> "Cris" <central_p at hotmail.com> wrote in message
>> news:e0lg9c$27q4$1 at digitaldaemon.com...
>>> Why the properties in D do not use the set/get syntax? It looks more 
>>> clear
>>> and natural to me.
>>
>> I agree.  With an explicit property syntax, more information could be 
>> given
>> to the compiler as well, enabling things like
>>
>> obj.prop += 5;
>>
>> Which is currently not possible.
>>
> 
> This is a compelling reason to have a specific syntax for properties.
> 
> --Derek Parnell
> Melbourne, Australia

  votes++



More information about the Digitalmars-d mailing list