Debugging on MacOS X (XCode) with lldb?
-
If there is a better forum area for me to post this in, please let me know.
I'm interested in viewing values such as QString in XCode 4.3 or newer, which now uses lldb. Python scripts are used to do this. The documentation on Nokia's QT site is outdated, and lists GDB as the debugger on MacOS X, and states that Python scripts are not an option.
Has anyone already written Python scripts to handle this, so complex variables can be viewed directly in the debugger?
-
The link to the outdated Nokia page I reference:
http://doc.qt.nokia.com/qtcreator-2.5/creator-debugging-helpers.html
-
I found that the way to do this is not by using Python scripts, but by using "Set Summary Format" in the pop-up menu when you right-click on a variable name while debugging. You then type in, for QStrings:
{(const char *)$VAR.toUtf8().constData()}:s
This crashed in my copy of XCode 4.3, but works in XCode 4.4 developer preview.