in an iphone application I created and extension class to the NSString.
NSString+Extensions.m
class
In one of the methods I need to convert the string to NSMutableString.
I tried to use this:
NSMutableString * stringToManipulate = [NSMutableString stringWithString:self];
But it is giving a warning:
Incompatible pointer types sending 'const Class' to parameter of type 'NSString *'
To my knowlede self is a reference to the string I called the method on, right? so why shouldn't it be of type NSString*? knowing that I can use the usual NSString methods on self.
Any idea on this issue?
Thanks