开发者

Objective C - are there two versions?

So Obj C is mainly used by Apple to program Cocoa apps. But I more interested in utilizing the OOP of Obj C, I'm not trying to code Cocoa apps and am not really interested in making GUI apps with it either, I was just wondering are there two versions of Obj C? GNU and Apple? cause I was reading wikipedia, under the section "Forwarding" where objects can forward messages to other objects that can handle the message.

forwarding methods:

- (retval_t)forward:(SEL)sel args:(arglist_t)a开发者_C百科rgs; // with GCC
- (id)forward:(SEL)sel args:(marg_list)args; // with NeXT/Apple systems

action methods:

- (retval_t)performv:(SEL)sel args:(arglist_t)args;  // with GCC
- (id)performv:(SEL)sel args:(marg_list)args; // with NeXT/Apple systems


Pretty much. Apple and GCC have diverged in their implementation of the Objective-C language, though a lot of code is still source-compatible.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜