Created
June 24, 2014 16:32
-
-
Save jakebromberg/7cf6b8496409e5ef38d1 to your computer and use it in GitHub Desktop.
NSString Block Append
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@interface NSString (Append) | |
- (NSString *(^)(NSString *))append __attribute__((const)); | |
@end | |
@implementation NSString (Append) | |
- (NSString *(^)(NSString *))append | |
{ | |
return ^NSString *(NSString *append) | |
{ | |
return [self stringByAppendingString:append]; | |
}; | |
} | |
@end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment