OCUDL icon indicating copy to clipboard operation
OCUDL copied to clipboard

User defined literals for Objective-C

Results 3 OCUDL issues
Sort by recently updated
recently updated
newest added

First off, awesome wizardry using the runtime and the new autoboxing to make this library. Really impressive! I converted the `$` macro to use `__VA_ARGS__` to allow as many arguments...

I wanted to suggest a tweak on the syntax, something like: ``` $(NSURLRequest)[@"http://apple.com"]; $(NSURL)[@"http://apple.com"]; $(UIColor)[0xff0000]; ``` This can be implemented with the following macro: ``` #define $(cls) (cls *)((id)[cls class])...

It would be interesting to do: ``` objc PhoneNumber* num = $(555-666-7777); ``` This would also allow the NSUUID literal to be simplified to not require "uuid" at the end.