Does one have to release objects allocated by class functions in NSString
Once the function returns, does one have to release the object after use? Or is it added to the autorelease pool by the class methods?
Thanks,
-TRS
MacBook, Mac OS X (10.5.2)
Want to highlight a helpful answer? Upvote!
Did someone help you, or did an answer or User Tip resolve your issue? Upvote by selecting the upvote arrow. Your feedback helps others! Learn more about when to upvote >
Did someone help you, or did an answer or User Tip resolve your issue? Upvote by selecting the upvote arrow. Your feedback helps others! Learn more about when to upvote >
MacBook, Mac OS X (10.5.2)
NSString *myString = [[NSString alloc] init]; // Belongs to you
NSString *myString = [NSString stringWithFormat:@"%@", anObject]; //Belongs to NSString
Does one have to release objects allocated by class functions in NSString