When does an associated object get released?

Even larger than your -dealloc issue is this:

UIKit is not KVO-compliant

No effort has been made to make UIKit classes key-value observable. If any of them are, it is entirely coincidental and is subject to break at Apple’s whim. And yes, I work for Apple on the UIKit framework.

This means that you’re going to have to find another way to do this, probably by changing your view layouting slightly.

Leave a Comment