gwynne/MAKVONotificationCenter — comment on commit 9db3c4de967796470fc5e043e4642a2973757d47
File: MAKVONotificationCenter.m line 152
By mikeash:

For really ironclad safety, I think this key needs to be used with `&`, lest someone else define the same string as a key and have it get coalesced into the same pointer. Unlikely to actually happen, but.... (This goes for all uses of this key, of course.)

More importantly, this set ends up being hidden shared data, and so access to these sets really needs to be synchronized for thread safety. Even if we say the API is not thread safe (and it would be good if it was), it's unreasonable to expect the caller to treat separate observations as being unusuable from different threads simultaneously, and especially not for separate notification centers altogether.