summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2016-05-27 11:34:20 +0200
committerLiang Qi <liang.qi@qt.io>2016-05-27 11:34:25 +0200
commit1d0a02f8a227286dbc383f890a1fd61e9139c223 (patch)
tree9780d50e500af6f6291d64f2e09431faa6f1fa13 /src
parent9eb5086aebc7dd01a444778d0885cc1959e4a901 (diff)
parentabcb49adcc640817b37d4ba8f0c10712a857d434 (diff)
Merge remote-tracking branch 'origin/5.6.1' into 5.7.0v5.7.0-rc1
Diffstat (limited to 'src')
-rw-r--r--src/linguist/lupdate/cpp.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/linguist/lupdate/cpp.cpp b/src/linguist/lupdate/cpp.cpp
index 02a667320..e53994c76 100644
--- a/src/linguist/lupdate/cpp.cpp
+++ b/src/linguist/lupdate/cpp.cpp
@@ -1848,16 +1848,16 @@ void CppParser::parseInternal(ConversionData &cd, const QStringList &includeStac
}
}
- if (yyTok == Tok_Colon) {
- // Skip any token until '{' since we might do things wrong if we find
- // a '::' token here.
+ if (yyTok == Tok_Colon || yyTok == Tok_Other) {
+ // Skip any token until '{' or ';' since we might do things wrong if we find
+ // a '::' or ':' token here.
do {
yyTok = getToken();
if (yyTok == Tok_Eof)
goto goteof;
if (yyTok == Tok_Cancel)
goto case_default;
- } while (yyTok != Tok_LeftBrace);
+ } while (yyTok != Tok_LeftBrace && yyTok != Tok_Semicolon);
} else {
if (yyTok != Tok_LeftBrace) {
// Obviously a forward declaration. We skip those, as they