Re: Classes incompatible with weak references
Re: Classes incompatible with weak references
- Subject: Re: Classes incompatible with weak references
- From: Kyle Sluder <email@hidden>
- Date: Wed, 15 Aug 2012 16:59:03 -0700
On Tue, Aug 14, 2012, at 12:09 AM, Vincent Habchi wrote:
> Using part of pointer to do something else than record an address is
> perilous.
NSNumber does exactly that on 10.7 and higher. Tagged pointers are a
well-understood technique.
You just have to be careful not to dereference them directly. The
runtime is able to understand a tagged pointer. Yet more reasons why
directly accessing isa is a bad idea.
--Kyle Sluder
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden