![]() |
Qt 6.x
The Qt SDK
|
Dumps or compares AST in an xml like format, mostly for testing/debugging. More...
Dumps or compares AST in an xml like format, mostly for testing/debugging.
Initialize it with a lambda that dumps a string, and configure it with .setX methods. If \l{indent} is set to a non zero value the xml is indented by that amount, and \l{baseIndent} is the initial indent. If \l{emitNode} is true the node tag is emitted in the preVisit/postVisit. If \l{emitLocation} is true the SourceLocations are emitted. If \l{emitAnnotations} is true annotations are emitted
The implementation has unnecessary roundtrips to QString, but it is supposed to be used for debugging purposes...
Probably you will not use the visitor at all but rather the static method diff or the qDebug() and ostream operator << that use the visitor...