diff options
author | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2018-01-10 15:54:46 +0100 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2018-01-10 18:32:52 +0000 |
commit | 6318a43ffc473ba101c955d96b39bc1b93ef7e61 (patch) | |
tree | 8b47deb373e2f35bd006fd71a9cfa4c2373b4750 /src | |
parent | d7457460abac9023780c21b69af6c2ba201a47d7 (diff) |
Introduce Q_FALLTHROUGH()
Silence g++ 7.X warnings.
Change-Id: Iba80ab547111d883ff8b3e99173cc5f3a79ae81f
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/plugins/qmltooling/qmldbg_debugger/qv4debugger.cpp | 2 | ||||
-rw-r--r-- | src/qml/parser/qqmljslexer.cpp | 2 | ||||
-rw-r--r-- | src/quick/items/qquickopenglshadereffect.cpp | 2 | ||||
-rw-r--r-- | src/quick/items/qquickpincharea.cpp | 3 |
4 files changed, 5 insertions, 4 deletions
diff --git a/src/plugins/qmltooling/qmldbg_debugger/qv4debugger.cpp b/src/plugins/qmltooling/qmldbg_debugger/qv4debugger.cpp index 1581cf637d..45817ea38e 100644 --- a/src/plugins/qmltooling/qmldbg_debugger/qv4debugger.cpp +++ b/src/plugins/qmltooling/qmldbg_debugger/qv4debugger.cpp @@ -189,7 +189,7 @@ void QV4Debugger::maybeBreakAtInstruction() case StepOver: if (m_currentFrame != m_engine->currentStackFrame) break; - // fall through + Q_FALLTHROUGH(); case StepIn: pauseAndWait(Step); return; diff --git a/src/qml/parser/qqmljslexer.cpp b/src/qml/parser/qqmljslexer.cpp index 78ed5e3b2c..bf56307e39 100644 --- a/src/qml/parser/qqmljslexer.cpp +++ b/src/qml/parser/qqmljslexer.cpp @@ -773,7 +773,7 @@ again: u = QLatin1Char('\0'); break; } - // fall through + Q_FALLTHROUGH(); case '1': case '2': case '3': diff --git a/src/quick/items/qquickopenglshadereffect.cpp b/src/quick/items/qquickopenglshadereffect.cpp index 94a5b6a646..2d3f500499 100644 --- a/src/quick/items/qquickopenglshadereffect.cpp +++ b/src/quick/items/qquickopenglshadereffect.cpp @@ -139,7 +139,7 @@ namespace { expected = TypeIdentifier; break; } - // Fall through. + Q_FALLTHROUGH(); case TypeIdentifier: typeIndex = idIndex; typeLength = idLength; diff --git a/src/quick/items/qquickpincharea.cpp b/src/quick/items/qquickpincharea.cpp index 476acd3a3e..9f10705449 100644 --- a/src/quick/items/qquickpincharea.cpp +++ b/src/quick/items/qquickpincharea.cpp @@ -644,7 +644,8 @@ bool QQuickPinchArea::childMouseEventFilter(QQuickItem *i, QEvent *e) return QQuickItem::childMouseEventFilter(i, e); switch (e->type()) { case QEvent::TouchBegin: - clearPinch(); // fall through + clearPinch(); + Q_FALLTHROUGH(); case QEvent::TouchUpdate: { QTouchEvent *touch = static_cast<QTouchEvent*>(e); d->touchPoints.clear(); |