On Nov 15, 2011, at 9:55 AM, Kyle Sluder wrote:

>> FWIW I check on the llvm IRC channel and the response was "I wouldn't
>> be surprised if there are annoying edge cases, but offhand I don't see
>> any reason it couldn't be done."
> 
> If it could've been done, they would have done it. The fragile base class 
> problem is a well-understood aspect of language design, and the compiler team 
> is full of smart people.

Yup. Rather, to be pedantic, it can be done, and they did do it, but at the 
cost of changes to object layout and the ABI. So to avoid breaking binary 
compatibility with all existing apps, they didn’t make these changes in the 
32-bit x86 runtime, only newer runtimes like 64-bit and iOS.

(In a nutshell: if a class doesn’t know the size of its base class’s instance 
data at compile time, it can’t look up its own instance variables as constant 
offsets from ‘self’, so this changes the machine instructions for getting and 
setting instance variables.)

—Jens

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to