-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
Qt Creator 4.7.0
-
-
f4dc3fd5c519e9181db5d241eee989b0284950db (qt-creator/qt-creator/master)
Currently, Qt Creator does not always show pointer types as such in the debugger.
Steps to reproduce:
1) Set up a new project with the sample program given at the end that uses `QString` pointer types.
2) set up the project to use either GDB or LLDB as debugger
3) set a breakpoint for the `return a.exec()`
4) start program in debugger
5) check what the debugger view shows for the local variables, in particular `str`, `ptr` and `ptrptr`
Result:
The following values are shown in the "Name", "Value" and "Type" columns:
- str, "hello", QString
- ptr, "hello", QString
- ptrptr, "hello", QString
Expected result:
Since `ptr` and `ptrptr` are of pointer types `QString*` and `QString**`, those should be shown in their "Type" column, i.e.:
- str, "hello", QString
- ptr, "hello", QString *
- ptrptr, "hello", QString * *
Small sample program:
#include <QCoreApplication>
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
QString str("hello");
QString *ptr = &str;
QString **ptrptr = &ptr;
return a.exec();
}
I also tested this with the current development version (master branch as of commit 0f96f735f009a8f79a97ef81183bb43eaedc3a1e).