What is a non-fragile ABI?

前端 未结 2 1482
走了就别回头了
走了就别回头了 2020-12-29 15:34

It may seem implied that everyone knows what a \"Non Fragile ABI\" is - considering the frequency and matter-of-fact-nature to which it is referred to - within Xcod

2条回答
  •  灰色年华
    2020-12-29 15:35

    The non-fragile ABI refers to the ability to add instance variables to a class without requiring recompilation of all subclasses.

    I.e. in v1 (there really aren't true versions of ObjC), if Apple were to add an instance variable to, say, NSView (on Cocoa, 32 bit), then every subclass of NSView (or subclass of subclass) would have to be recompiled or they would blow up. v2 and v3 fix this.

    It is explained in detail in this weblog post.

    The documentation you are referring to is in the llvm/clang man page. Pretty rare place to be for most developers most of the time; unless you are writing a Makefile that is driving the compiler directly, there isn't much reason to read that page (unless spelunking -- which is quite educational, of course).

    It is written in the style of a Unix man page and, no surprise, is a bit... obtuse. For almost all tasks, it is best to stick to the higher level documentation. I.e. the Xcode build settings documentation is general quite a bit less obtuse.

提交回复
热议问题