Implemented support for C++ and iso646 operators.

This commit is contained in:
Roberto Raggi
2008-12-10 13:27:59 +01:00
parent 824db4c6e7
commit 65f07aa2de
4 changed files with 158 additions and 3 deletions

View File

@@ -589,8 +589,13 @@ void Lexer::scan_helper(Token *tok)
tok->kind = classify(yytext, yylen, _qtMocRunEnabled);
else
tok->kind = T_IDENTIFIER;
if (tok->kind == T_IDENTIFIER && control())
tok->identifier = control()->findOrInsertIdentifier(yytext, yylen);
if (tok->kind == T_IDENTIFIER) {
tok->kind = classifyOperator(yytext, yylen);
if (control())
tok->identifier = control()->findOrInsertIdentifier(yytext, yylen);
}
break;
} else if (std::isdigit(ch)) {
const char *yytext = _currentChar - 1;