Enumeration with Support of "With"

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
c4s
Addict
Addict
Posts: 1981
Joined: Thu Nov 01, 2007 5:37 pm
Location: Germany

Enumeration with Support of "With"

Post by c4s »

Almost always enumerations have something common prepended, like:

Code: Select all

Enumeration
	#NAMESPACE_MY_CONSTANT_ONE
	#NAMESPACE_MY_CONSTANT_TWO
	#NAMESPACE_MY_CONSTANT_THREE
EndEnumeration
How about making it easier on the eyes (and more intuitive to modify) by introducing an extra keyword like "With". The following example would create the same constants as above:

Code: Select all

Enumeration With NAMESPACE_MY_CONSTANT_
	#ONE
	#TWO
	#THREE
EndEnumeration
By the way: When I checked if this was already requested, I noticed that there are a couple of threads for binary enumeration. Now that we have EnumerationBinary (PB5.40), they can be marked as [Implemented]. :)
If any of you native English speakers have any suggestions for the above text, please let me know (via PM). Thanks!
User avatar
Demivec
Addict
Addict
Posts: 4260
Joined: Mon Jul 25, 2005 3:51 pm
Location: Utah, USA

Re: Enumeration with Support of "With"

Post by Demivec »

I have no comment on the request, though it could be useful.
c4s wrote:By the way: When I checked if this was already requested, I noticed that there are a couple of threads for binary enumeration. Now that we have EnumerationBinary (PB5.40), they can be marked as [Implemented].
In case somebody wants to update them here are a few of the requests:

viewtopic.php?p=392839
viewtopic.php?f=3&t=61670
viewtopic.php?f=3&t=55506
viewtopic.php?f=3&t=52244
viewtopic.php?f=3&t=40649
viewtopic.php?f=3&t=38281
viewtopic.php?f=3&t=31142
viewtopic.php?f=3&t=23821
Post Reply