Reputation: 18488
I was just wondering if there is any need besides backwards compatibility to keep the @private keyword in objective-c, since class extensions provide a much better way to declare your private iVars. Are there any other reasons for keeping the @private directive?.
Upvotes: 2
Views: 123
Reputation: 185681
The 32-bit x86 architecture still requires declaring ivars in the primary @interface
block. The ability to synthesize ivars (via properties or class extensions or on the @implementation
) is only available for 64-bit x86 and ARM architectures (and, presumably, any future architecture as well).
Upvotes: 1