2

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?.

4

1 に答える 1

1

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).

于 2012-10-09T19:35:12.430 に答える