Cleaner property syntax

Remember, just because you request it, that doesn't mean you'll get it.

Moderator: GZDoom Developers

argv
Posts: 184
Joined: Tue Aug 30, 2016 4:47 pm

Cleaner property syntax

Post 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;
ZippeyKeys12
Posts: 111
Joined: Wed Jun 15, 2016 2:49 pm

Re: Cleaner property syntax

Post 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.
argv
Posts: 184
Joined: Tue Aug 30, 2016 4:47 pm

Re: Cleaner property syntax

Post by argv »

Like this?

Code: Select all

property SomeProperty: int SomeField1, bool SomeField2;
ZippeyKeys12
Posts: 111
Joined: Wed Jun 15, 2016 2:49 pm

Re: Cleaner property syntax

Post by ZippeyKeys12 »

argv wrote:Like this?

Code: Select all

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

Return to “Feature Suggestions [GZDoom]”