Recent Changes in Objective-C runtime/ Xcode 4.2 code-Collection of common programming errors
I’ve just started learning Obj-C and i’m a little confused. The videos I’ve been watching on Lynda.com were created with Xcode 4, but there are so many differences that I find it hard to believe that all of them occurred in 2 point releases. For instance:
In the video you could write:
@property NSString * myString
And it would be fine, but now in 4.2 it throws an error unless you write something like:
@property (nonatomic, retain) NSString * myString
In addition, there are no longer init or dealloc methods in the implementation code by default and NSAutoReleasePool is implemented completely differently. What gives?