Important: Please read the Qt Code of Conduct -

QDebug usage question

  • Hi, I am new to the forum and Qt programming, so please forgive me if this has an obvious answer that I can not see. I just upgraded to Qt 5.3.2 from 5.2.1 and experiencing some difficulty with my QDebug statements. The following code sample worked fine in 5.2.1 but now it is displaying a double quote at the end of the output:

    @qDebug() << "!n" << tr("[%1] Mounted %2 as %3")

    and the output from the above looks like this:
    @[Disk 1] Mounted SDX Boot - Ultimate.atr as DD Diskette (180k)"@

    as you can see there is an extraneous " at the end of the output line, this didn't happen with Qt 5.2.1, so I am wondering what has changed since 5.2.1 or is this a problem with 5.3.2

  • Lifetime Qt Champion

    Hi and welcome to devnet,

    Just checked with 5.3.3 (built from git) and got something like

    @!n "[Disk 1] Mounted SDX Boot - Ultimate.atr as DD Diskette (180k)"@

    What OS are you running ?

  • Oh sorry, forgot to mention that I am on Windows 7 Ultimate 64 bit (SP1)

  • Lifetime Qt Champion

    I couldn't reproduce it with the latest 5.4 from git

  • Hmm, maybe I'll try 5.4 and see what happens, I have quite a few of those QDebug statements in the code that produce the extra " at the end of the line.
    Thanks for checking it.

Log in to reply