by thingsdoer · 13y ago · 0 comments
The reality is, that NSString needs native formatting sugar. Anything else would really just be a hack. I'm not particularly even happy with the [@"Hello ":@"World] syntax, either.
NSString *newS = @"blah " + @(42) + @"!"; newstr = [@"%d %@" format 42, @"blah"];
Implement it as a method that takes a dummy parameter, plus a macro: - (NSString *)format:(int)dummy, ...
#define format format:0,
Awful way to do it, but the resulting syntax is not entirely terrible.