Page 1 of 1

Cleaner property syntax

Posted: Sat Jul 07, 2018 9:27 pm
by argv
The current syntax for declaring a property mapped to a single field (a very common pattern) is rather verbose:

Code: Select all

int SomeProperty;
property SomeProperty: SomeProperty;
This could be shortened:

Code: Select all

property int SomeProperty;

Re: Cleaner property syntax

Posted: Thu Jul 12, 2018 2:33 pm
by ZippeyKeys12
This will only work for single-variable, same-name properties.
It would be nice if there was a better way, that also applied to more cases.

Re: Cleaner property syntax

Posted: Thu Jul 12, 2018 6:05 pm
by argv
Like this?

Code: Select all

property SomeProperty: int SomeField1, bool SomeField2;

Re: Cleaner property syntax

Posted: Fri Jul 20, 2018 12:25 am
by ZippeyKeys12
argv wrote:Like this?

Code: Select all

property SomeProperty: int SomeField1, bool SomeField2;
Yeah, exactly