summaryrefslogtreecommitdiffstats
path: root/src/corelib/xml/qxmlstream_p.h
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@theqtcompany.com>2016-06-27 15:43:33 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2016-08-19 18:38:53 +0000
commit9f888d2fde9c5413e5519e0914e9b13638760985 (patch)
tree7e211a2ae70c272ea8041d5100f0c9a67b32de1b /src/corelib/xml/qxmlstream_p.h
parent25dd9c521fc064a71db63b110b7973225ee20c02 (diff)
Support C++17 fallthrough attribute
Replaces our mix of comments for annotating intended absence of break in switches with the C++17 attribute [[fallthrough]], or its earlier a clang extension counterpart. Change-Id: I4b2d0b9b5e4425819c7f1bf01608093c536b6d14 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/xml/qxmlstream_p.h')
-rw-r--r--src/corelib/xml/qxmlstream_p.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/corelib/xml/qxmlstream_p.h b/src/corelib/xml/qxmlstream_p.h
index c68d6f0f53..b62cc9ac39 100644
--- a/src/corelib/xml/qxmlstream_p.h
+++ b/src/corelib/xml/qxmlstream_p.h
@@ -1048,7 +1048,7 @@ bool QXmlStreamReaderPrivate::parse()
dtdName.clear();
dtdPublicId.clear();
dtdSystemId.clear();
- // fall through
+ Q_FALLTHROUGH();
case QXmlStreamReader::Comment:
case QXmlStreamReader::Characters:
isCDATA = false;
@@ -1080,7 +1080,7 @@ bool QXmlStreamReaderPrivate::parse()
return false;
}
#endif
- // fall through
+ Q_FALLTHROUGH();
default:
clearTextBuffer();
;
@@ -1124,7 +1124,7 @@ bool QXmlStreamReaderPrivate::parse()
} else {
break;
}
- // fall through
+ Q_FALLTHROUGH();
case ~0U: {
token = EOF_SYMBOL;
if (!tagsDone && !inParseEntity) {
@@ -1338,7 +1338,7 @@ bool QXmlStreamReaderPrivate::parse()
case 17:
case 18:
dtdName = symString(3);
- // fall through
+ Q_FALLTHROUGH();
case 19:
case 20:
@@ -1480,7 +1480,7 @@ bool QXmlStreamReaderPrivate::parse()
if (entityDeclaration.parameter)
raiseWellFormedError(QXmlStream::tr("NDATA in parameter entity declaration."));
}
- //fall through
+ Q_FALLTHROUGH();
case 94:
case 95: {
@@ -1588,7 +1588,7 @@ bool QXmlStreamReaderPrivate::parse()
case 129:
isWhitespace = false;
- // fall through
+ Q_FALLTHROUGH();
case 130:
sym(1).len += fastScanContentCharList();
@@ -1760,7 +1760,7 @@ bool QXmlStreamReaderPrivate::parse()
case 236:
isEmptyElement = true;
- // fall through
+ Q_FALLTHROUGH();
case 237:
setType(QXmlStreamReader::StartElement);