[Qt-creator] Debugging helper for forward declared classes (PIMPL)

resurrection at centrum.cz resurrection at centrum.cz
Sun May 12 12:42:33 CEST 2019

I have a problem creating a debugging helper for classes that does use only forward-declared data member like when using PIMPL:
- MyClass.h
    struct MyClassPrivate;
    class MyClass
        MyClassPrivate *d;
- MyClass.cpp
    struct MyClassPrivate
        int i;
And the debugging helper:
def qdump__MyClass(d, value):
    with Children(d):
        d.putSubItem("Number", value["d"]["i"])
Only place when debugging helper for MyClass works is in the implementation file of MyClass.cpp. In all other places the MyClassPrivate is just forward declared type and the pointer to it is completely opaque to the debugging helper engine unless I step into the MyClass.cpp where the type is defined.
I may be asking for the impossible, but is there a way to work around this somehow?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qt-creator/attachments/20190512/c48ae5b7/attachment.html>

More information about the Qt-creator mailing list