From 6ce2f3f26bf08b4c6952f492a3731eb4fe5a42bc Mon Sep 17 00:00:00 2001 From: Lars Schmertmann Date: Sat, 27 Jun 2020 14:18:09 +0200 Subject: Add ; to Q_UNUSED This is required to remove the ; from the macro with Qt 6. Task-number: QTBUG-82978 Change-Id: I3f0b6717956ca8fa486bed9817b89dfa19f5e0e1 Reviewed-by: Friedemann Kleint --- tests/manual/diaglib/debugproxystyle.cpp | 2 +- tests/manual/embeddedintoforeignwindow/main.cpp | 6 +++--- tests/manual/filetest/main.cpp | 4 ++-- tests/manual/foreignwindows/main.cpp | 2 +- tests/manual/qnetworkreply/main.cpp | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) (limited to 'tests/manual') diff --git a/tests/manual/diaglib/debugproxystyle.cpp b/tests/manual/diaglib/debugproxystyle.cpp index dc95241473..002220507b 100644 --- a/tests/manual/diaglib/debugproxystyle.cpp +++ b/tests/manual/diaglib/debugproxystyle.cpp @@ -63,7 +63,7 @@ QDebug operator<<(QDebug debug, const QStyleOption *option) debug << ", \"" << (textSize < 20 ? ivo->text : ivo->text.left(20) + QLatin1String("...")) << '"'; debug << ", "; #else // Qt 5 - Q_UNUSED(ivo) + Q_UNUSED(ivo); #endif } else { debug << "QStyleOption("; diff --git a/tests/manual/embeddedintoforeignwindow/main.cpp b/tests/manual/embeddedintoforeignwindow/main.cpp index 8edb3a3e9b..d6cff8ac04 100644 --- a/tests/manual/embeddedintoforeignwindow/main.cpp +++ b/tests/manual/embeddedintoforeignwindow/main.cpp @@ -111,7 +111,7 @@ static void showNativeWindow(WId wid) #ifdef Q_OS_WIN ShowWindow(HWND(wid), SW_SHOW); #else // Q_OS_WIN - Q_UNUSED(wid) + Q_UNUSED(wid); Q_UNIMPLEMENTED(); #endif } @@ -121,7 +121,7 @@ static void setFocusToNativeWindow(WId wid) #ifdef Q_OS_WIN SetFocus(HWND(wid)); #else // Q_OS_WIN - Q_UNUSED(wid) + Q_UNUSED(wid); Q_UNIMPLEMENTED(); #endif } @@ -131,7 +131,7 @@ static void destroyNativeWindow(WId wid) #ifdef Q_OS_WIN DestroyWindow(HWND(wid)); #else // Q_OS_WIN - Q_UNUSED(wid) + Q_UNUSED(wid); Q_UNIMPLEMENTED(); #endif } diff --git a/tests/manual/filetest/main.cpp b/tests/manual/filetest/main.cpp index 22c74af327..290dc7064e 100644 --- a/tests/manual/filetest/main.cpp +++ b/tests/manual/filetest/main.cpp @@ -197,7 +197,7 @@ static int rm(const char *fileName) static int rmr(const char *dirName) { #if QT_VERSION < 0x050000 - Q_UNUSED(dirName) + Q_UNUSED(dirName); return 1; #else QDir dir(QString::fromLocal8Bit(dirName)); @@ -213,7 +213,7 @@ static int rmr(const char *dirName) int main(int argc, char *argv[]) { QCoreApplication a(argc, argv); - Q_UNUSED(a) + Q_UNUSED(a); if (argc >= 3 && !qstrcmp(argv[1], "ls")) return ls(argc -2, const_cast(argv + 2), true); diff --git a/tests/manual/foreignwindows/main.cpp b/tests/manual/foreignwindows/main.cpp index cad71d183a..cc5b16391c 100644 --- a/tests/manual/foreignwindows/main.cpp +++ b/tests/manual/foreignwindows/main.cpp @@ -82,7 +82,7 @@ static WId createInternalWindow(const QString &name) } } #else // Q_OS_WIN - Q_UNUSED(name) + Q_UNUSED(name); #endif return result; } diff --git a/tests/manual/qnetworkreply/main.cpp b/tests/manual/qnetworkreply/main.cpp index 1086498553..0ba8a19913 100644 --- a/tests/manual/qnetworkreply/main.cpp +++ b/tests/manual/qnetworkreply/main.cpp @@ -175,7 +175,7 @@ void tst_qnetworkreply::setSslConfiguration() #elif defined(Q_OS_MAC) QCOMPARE(rootCertLoadingAllowed, false); #else - Q_UNUSED(rootCertLoadingAllowed) + Q_UNUSED(rootCertLoadingAllowed); #endif // other platforms: undecided (Windows: depends on the version) if (works) { QCOMPARE(reply->error(), QNetworkReply::NoError); -- cgit v1.2.3