On 23 Sep 2016, at 10:04, Quincey Morris <quinceymor...@rivergatesoftware.com> wrote: > >> static void* kMyContext = &kMyContext; > > That makes the “&” optional (at comparison time), and it should even avoid > the coalescing problem if it’s declared const.
Yes, that’s a good way to do it. It might be a good idea for Apple to have a macro for this purpose, so you could write NS_DECLARE_KVO_CONTEXT(kMyContext); as that would avoid any confusion whatsoever (filed as rdar://28444442). Kind regards, Alastair. -- http://alastairs-place.net _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com