I wanna use double pointer and I tried to declare like this.
NSString **a;
but, Xcode showed me the error "Pointer to non-const type 'NSString *' with no explicit ownership" and it couldn't be compiled.
Finally I wanna do like this.
NSString **a;
NSString *b = @"b";
NSString *c = @"c";
a = &b;
*a = c;
NSLog(@"%@",b);//I wanna see "c"
Let me know any advise please.
NSString *__strong *a;
– Oballa**
s to refer to objects is really quite rare in Objective-C. Also, @H2CO3, one of the goals of ARC was to make uncommon, fragile, coding patterns (that often cause bugs) quite precise in declaration. This is one of those cases. "Turn off ARC" is not a constructive suggestion; many of us have fully embraced ARC and have seen a drastic reduction in code fragility because of it exactly because the compiler is able to be significantly more thorough in its analysis. – Microscope