views:

253

answers:

3

When I debug, I never get the value of an NSString inside of an array. All I see are cryptic symbols, probably memory addresses of something like 0x1dc3753. I dig into all the stuff and expand everything, but no humanly readable value at all. Not really useful at all. How do you go about this (besides NSLogging everything)?

A: 

Set a breakpoint near the array you want to inspect and hover over the array variable. Then, hover just to right of the triangle that appears and you should have an icon appear which is two triangles (above each other). Click on this and select "Print description" from the menu.

pheelicks
+1  A: 

You should be able to see at least an abbreviated string in the variables pane when you expand a NSMutableArray. If you can't, that suggest you don't actually have strings as elements.

In the variables pane, control-click and from the pop-up menu select Show Type Column. Then when you drilled down into the array, it will show you the class of each element.

TechZen
A: 

Also, same thing as 'Print Description' is to type po variableName in the debugger console.

St3fan