DIP4: Properties

BLS windevguy at hotmail.de
Sun Jul 26 13:41:05 PDT 2009


BLS wrote:
> Nick Sabalausky wrote:
>>  An alternate usage/definition syntax for properties.
>>
>> http://prowiki.org/wiki4d/wiki.cgi?LanguageDevel/DIPs/DIP4
>>
>> Note that there are a few parts marked NEED HELP, that could use 
>> assistance from someone with more expertise in this than me.
>>
>>
> 
> A one liner should do the trick too.
> [public] [const] property int i;
> 
> public -> delphi published
> const -> readonly / getter
> 
> the compiler can generate getter and setter code.

I am a little bit ''' about the feedback :
Is there really nobody who got it :


immutable property int i -> becomes :

pure int get_i() nothrow
{
  return i
}

take the rest of the syntax and tell me where the leak is.



More information about the Digitalmars-d mailing list