summaryrefslogtreecommitdiffstats
path: root/src/scanner.l
diff options
context:
space:
mode:
Diffstat (limited to 'src/scanner.l')
-rw-r--r--src/scanner.l7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/scanner.l b/src/scanner.l
index 6bbf1c4..9a3d27f 100644
--- a/src/scanner.l
+++ b/src/scanner.l
@@ -624,6 +624,11 @@ IDLATTR ("["[^\]]*"]"){BN}*
TYPEDEFPREFIX (("typedef"{BN}+)?)((("volatile"|"const"){BN}+)?)
RAWBEGIN (u|U|L|u8)?R\"[^ \t\(\)\\]{0,16}"("
RAWEND ")"[^ \t\(\)\\]{0,16}\"
+ARITHOP "+"|"-"|"/"|"*"|"%"|"--"|"++"
+ASSIGNOP "="|"*="|"/="|"%="|"+="|"-="|"<<="|">>="|"&="|"^="|"|="
+LOGICOP "=="|"!="|">"|"<"|">="|"<="|"&&"|"||"|"!"
+BITOP "&"|"|"|"^"|"<<"|">>"|"~"
+OPERATOR "operator"{B}*({ARITHOP}|{ASSIGNOP}|{LOGICOP}|{BITOP})
%option noyywrap
@@ -1938,7 +1943,7 @@ RAWEND ")"[^ \t\(\)\\]{0,16}\"
BEGIN(Using);
}
<Using>"namespace"{BN}+ { lineCount(); BEGIN(UsingDirective); }
-<Using>{ID}{BN}*({BN}*("::"|"."){BN}*{ID})* {
+<Using>({ID}{BN}*("::"|"."){BN}*)*({ID}|{OPERATOR}) {
lineCount();
current->name=yytext;
current->fileName = yyFileName;