diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/libs/3rdparty/cplusplus/Lexer.h | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/src/libs/3rdparty/cplusplus/Lexer.h b/src/libs/3rdparty/cplusplus/Lexer.h index 0d527f1d82..e2e39ed480 100644 --- a/src/libs/3rdparty/cplusplus/Lexer.h +++ b/src/libs/3rdparty/cplusplus/Lexer.h @@ -99,13 +99,9 @@ private: inline void yyinp() { - if (++_currentChar == _lastChar) - _yychar = 0; - else { - _yychar = *_currentChar; - if (_yychar == '\n') - pushLineStartOffset(); - } + _yychar = *++_currentChar; + if (Q_UNLIKELY(_yychar == '\n')) + pushLineStartOffset(); } void pushLineStartOffset(); |