ext/rbs_extension/lexer.re in rbs-2.4.0 vs ext/rbs_extension/lexer.re in rbs-2.5.0

- old
+ new

@@ -17,11 +17,11 @@ re2c:define:YYRESTORE = "*state = backup;"; re2c:yyfill:enable = 0; word = [a-zA-Z0-9_]; - operator = "/" | "~" | "[]" | "[]=" | "!" | "!=" | "!~" | "-" | "-@" | "+" | "+@" + operator = "/" | "~" | "[]=" | "!" | "!=" | "!~" | "-" | "-@" | "+" | "+@" | "==" | "===" | "=~" | "<<" | "<=" | "<=>" | ">" | ">=" | ">>" | "%"; "(" { return next_token(state, pLPAREN); } ")" { return next_token(state, pRPAREN); } "[" { return next_token(state, pLBRACKET); } @@ -43,9 +43,10 @@ "=>" { return next_token(state, pFATARROW); } "=" { return next_token(state, pEQ); } ":" { return next_token(state, pCOLON); } "::" { return next_token(state, pCOLON2); } "<" { return next_token(state, pLT); } + "[]" { return next_token(state, pAREF_OPR); } operator { return next_token(state, tOPERATOR); } number = [0-9] [0-9_]*; ("-"|"+")? number { return next_token(state, tINTEGER); }