I turned on a new flag in xcode and get the warning "Weak receiver may be unpredictably null in ARC mode". This confuses me because OF COURSE it could be nil.
相关问题
- Image loads in simulator but not device?
- Cast NSURL ** to CFURLRef *
- Strange “zombie” in forwardInvocation: + getArgume
- NSOutlineView drag line stuck + blue border
- UIModalTransitionStyleFlipHorizontal flips Vertica
相关文章
- Xcode: Is there a way to change line spacing (UI L
- Converting (u)int64_t to NSNumbers
- Can keyboard of type UIKeyboardTypeNamePhonePad be
- “getter” keyword in @property declaration in Objec
- How to get a CGImageRef from Context-Drawn Images?
- NSMenuItem KeyEquivalent “ ”(space) bug
- Why are my UIView layer properties not being set w
- create UIImageView
I asked this question a week ago and received no answer, but Greg Parker answered it on the mailing list. So I am reposting with the answer.
In my first incarnation of this question, I posted something like this, where I thought testing for nil should have been enough
The problem is that self.rootViewController could BECOME nill in the space between checking for nil and completing the method called. What we are told to do is to assign to a strong local reference and use that like so
Stephen Butler presented succinct restatement of the problem this warning is meant to combat