Create an NSCharacterSet constant
Create an NSCharacterSet constant
- Subject: Create an NSCharacterSet constant
- From: John Joyce <email@hidden>
- Date: Sun, 1 Nov 2009 23:19:52 -0600
Hi All,
Is it possible to create an NSCharacterSet constant?
Attempting to do so with the methods for creating an NSCharacterSet
naturally fails to compile with "initializer element is not constant"
I would ideally like to be able to do this.
Is it best just to declare a global constant string, then initialize
an NSCharacterSet during app initialization? It certainly seems that
is the only real option.
Am I missing something?
If I am correct in what I am seeing, would there not be a valid use
case for this as an extension of NSCharacterSet?
(BTW, thanks GCC for the less than clear error message which should
say "you cannot run functions or methods in a global initializer" or
something better.)
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden