I have a constant defined as:
#define BEGIN_IMPORT_STRING @"Importing Hands!";
But I get an error when I try to concat with:
NSString *updateStr = [NSString stringWithFormat:@"%@%@", BEGIN_IMPORT_STRING, @" - Reading "];
This doesn’t happen if I replace it with a string literal
NSString *updateStr = [NSString stringWithFormat:@"%@%@", @"foo", @" - Reading "];
Or a local string
NSString *temp = @"foo";
NSString *updateStr = [NSString stringWithFormat:@"%@%@", temp, @" - Reading "];
You need to remove the semicolon from your
#define:To the compiler, the resulting line looks like this: