"Print Description" equivalent in debugger?

Hi,

Is there a way to print the description of a variable in the debugger similar to Xcode's "Print Description" command?

I know you can use inspect value but there are times especially when trying to view the value of a core data entity that it would be useful to be able to print the value of the entity which may have been a fault initially.

Thx

3 comments
Comment actions Permalink

You can see parameters and stack values in the Debugger Tool Window->Variables view.
You also can use 'Evaluate' dialog (Alt-F8) to evaluate and see values of any arbitrary expression.
For basic types Debugger shows their values and for the Objective-C Objects - their descriptions.

0
Comment actions Permalink

Thx for the reply. I am familiar with the Variables View however there are certain cases where having the ability to print out to the console an objects value would still be desirable. For example if i have an array of objects and i want to search for a specific value in xcode i would print out the whole array and the search for the value. In AC i would have to manually open and search through each object in the array.

Also i am still having problems viewing the values for core data entities. If i choose to inspect element then all the key/values show up as null. On the other hand if i drill down into the NSManagedObject and get to Properties it still doesnt give me a clean name/value and instead shows me a bunch of other variables.

Thx

0
Comment actions Permalink

To print variables you can use GDB/LLDB console that is also available in AppCode (see the screenshot)
As for the problems with values for various data, we would appreciate if you report these problems in YouTrack (with code snippets if possible)



Attachment(s):
Screen Shot 2011-09-14 at 11.27.05 .png
0

Please sign in to leave a comment.