diff options
author | Lars Schmertmann <Lars.Schmertmann@governikus.de> | 2020-07-02 15:56:26 +0200 |
---|---|---|
committer | Lars Schmertmann <Lars.Schmertmann@governikus.de> | 2020-07-03 21:10:09 +0200 |
commit | ae890390e523f0f435190654b081764df88d7b94 (patch) | |
tree | 9c19ed0c78a11c2fc875cb4b8d4c2087e251cf4b /tests/auto/corelib | |
parent | af3f5b8746a31caf8457590293e3e28101ef85e3 (diff) |
Avoid use of Q_UNUSED by eliminating the parameter names
This change only happens to files touched
by the commit to add missing ; to Q_UNUSED.
Task-number: QTBUG-82978
Change-Id: I10e6993a2bb3952cf9a262708b8573550e0dbe63
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'tests/auto/corelib')
-rw-r--r-- | tests/auto/corelib/io/qfile/tst_qfile.cpp | 3 | ||||
-rw-r--r-- | tests/auto/corelib/kernel/qmetaobjectbuilder/tst_qmetaobjectbuilder.cpp | 2 | ||||
-rw-r--r-- | tests/auto/corelib/kernel/qobject/tst_qobject.cpp | 19 |
3 files changed, 12 insertions, 12 deletions
diff --git a/tests/auto/corelib/io/qfile/tst_qfile.cpp b/tests/auto/corelib/io/qfile/tst_qfile.cpp index 9416796c6c..b81ed67764 100644 --- a/tests/auto/corelib/io/qfile/tst_qfile.cpp +++ b/tests/auto/corelib/io/qfile/tst_qfile.cpp @@ -2207,8 +2207,7 @@ public: uint ownerId(FileOwner) const { return 0; } QString owner(FileOwner) const { return QString(); } QDateTime fileTime(FileTime) const { return QDateTime(); } - bool setFileTime(const QDateTime &newDate, FileTime time) - { Q_UNUSED(newDate) Q_UNUSED(time) return false; } + bool setFileTime(const QDateTime &, FileTime) { return false; } private: int number; diff --git a/tests/auto/corelib/kernel/qmetaobjectbuilder/tst_qmetaobjectbuilder.cpp b/tests/auto/corelib/kernel/qmetaobjectbuilder/tst_qmetaobjectbuilder.cpp index 893479843f..a3dd5e05e1 100644 --- a/tests/auto/corelib/kernel/qmetaobjectbuilder/tst_qmetaobjectbuilder.cpp +++ b/tests/auto/corelib/kernel/qmetaobjectbuilder/tst_qmetaobjectbuilder.cpp @@ -121,7 +121,7 @@ private slots: protected slots: Q_SCRIPTABLE void slot4(int) {} - void slot5(int a, const QString& b) { Q_UNUSED(a); Q_UNUSED(b); } + void slot5(int, const QString &) {} signals: void sig1(); diff --git a/tests/auto/corelib/kernel/qobject/tst_qobject.cpp b/tests/auto/corelib/kernel/qobject/tst_qobject.cpp index 74725c8f18..231cccc38d 100644 --- a/tests/auto/corelib/kernel/qobject/tst_qobject.cpp +++ b/tests/auto/corelib/kernel/qobject/tst_qobject.cpp @@ -207,7 +207,11 @@ protected: Q_INVOKABLE QT_MOC_COMPAT void invoke2(int){} Q_SCRIPTABLE QT_MOC_COMPAT void sinvoke2(){} private: - Q_INVOKABLE void invoke3(int hinz = 0, int kunz = 0){Q_UNUSED(hinz) Q_UNUSED(kunz)} + Q_INVOKABLE void invoke3(int hinz = 0, int kunz = 0) + { + Q_UNUSED(hinz); + Q_UNUSED(kunz); + } Q_SCRIPTABLE void sinvoke3(){} int recursionCount; @@ -426,15 +430,12 @@ public: public slots: void on_Sender_signalNoParams() { called_slots << 1; } - void on_Sender_signalWithParams(int i = 0) { called_slots << 2; Q_UNUSED(i); } - void on_Sender_signalWithParams(int i, QString string) { called_slots << 3; Q_UNUSED(i);Q_UNUSED(string); } + void on_Sender_signalWithParams(int = 0) { called_slots << 2; } + void on_Sender_signalWithParams(int, QString) { called_slots << 3; } void on_Sender_signalManyParams() { called_slots << 4; } - void on_Sender_signalManyParams(int i1, int i2, int i3, QString string, bool onoff) - { called_slots << 5; Q_UNUSED(i1);Q_UNUSED(i2);Q_UNUSED(i3);Q_UNUSED(string);Q_UNUSED(onoff); } - void on_Sender_signalManyParams(int i1, int i2, int i3, QString string, bool onoff, bool dummy) - { called_slots << 6; Q_UNUSED(i1);Q_UNUSED(i2);Q_UNUSED(i3);Q_UNUSED(string);Q_UNUSED(onoff); Q_UNUSED(dummy);} - void on_Sender_signalManyParams2(int i1, int i2, int i3, QString string, bool onoff) - { called_slots << 7; Q_UNUSED(i1);Q_UNUSED(i2);Q_UNUSED(i3);Q_UNUSED(string);Q_UNUSED(onoff); } + void on_Sender_signalManyParams(int, int, int, QString, bool) { called_slots << 5; } + void on_Sender_signalManyParams(int, int, int, QString, bool, bool) { called_slots << 6; } + void on_Sender_signalManyParams2(int, int, int, QString, bool) { called_slots << 7; } void slotLoopBack() { called_slots << 8; } void on_Receiver_signalNoParams() { called_slots << 9; } void on_Receiver_signal_with_underscore() { called_slots << 10; } |