objective c - Debugger falsely shows object as nil until object has been used -


i set breakpoint following these lines:

nsinteger index = [self.acombobox indexofselecteditem]; nsstring *nameselected = [self.names objectatindex:index];  

if roll mouse on nameselected, shows value of “nil.” , if type “po nameselected” in debugger console, says string “does not appear point valid object.”

so added nslog print nameselected, duly printed string. and, once debugger below nslog line, if roll mouse on nameselected, shows correct value.

is there reason why debugger behaves way? makes harder identify real problem is.

me (and millions of other ios developers) time , have no issues. though seems stupid query, have made modifications source while debugging (specifically, added lines of code)? if so, debugger still pointing line x .o file while source out of sync.


Comments

Popular posts from this blog

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -

java - Android recognize cell phone with keyboard or not? -

iphone - How would you achieve a LED Scrolling effect? -