diff --git a/RegExpSupport/gen/org/intellij/lang/regexp/_RegExLexer.java b/RegExpSupport/gen/org/intellij/lang/regexp/_RegExLexer.java index 4527fb1a888c..730d7753361a 100644 --- a/RegExpSupport/gen/org/intellij/lang/regexp/_RegExLexer.java +++ b/RegExpSupport/gen/org/intellij/lang/regexp/_RegExLexer.java @@ -194,14 +194,14 @@ class _RegExLexer implements FlexLexer { "\1\26\1\27\1\30\1\27\1\31\1\32\1\33\1\10"+ "\1\34\1\35\1\2\1\36\1\37\1\22\1\40\1\41"+ "\1\42\1\43\1\44\1\45\1\1\1\24\1\46\1\47"+ - "\2\50\1\51\1\0\1\52\1\0\1\53\1\54\1\55"+ + "\2\50\1\51\2\0\1\52\1\0\1\53\1\54\1\55"+ "\1\56\1\57\1\60\1\10\1\61\1\62\1\63\1\64"+ "\1\10\1\64\1\65\2\66\1\67\1\70\1\71\1\72"+ "\1\73\1\74\1\75\1\10\1\76\1\77\1\100\1\0"+ "\1\101\1\102\1\103\1\104\1\0\1\105\1\106\1\107"+ "\1\110\1\111\1\0\1\112\1\0\1\113\1\0\1\114"+ "\1\0\1\115\1\116\1\117\2\72\1\120\1\121\1\122"+ - "\1\123\1\124\1\125\1\126\1\127\2\0\1\114\1\0"+ + "\1\123\1\124\1\125\1\126\1\127\1\0\1\114\1\0"+ "\1\130\2\72\1\120\1\131\1\114\1\72\1\120\1\72"+ "\1\132\4\72"; @@ -239,14 +239,14 @@ class _RegExLexer implements FlexLexer { "\0\u041e\0\u060e\0\u041e\0\u064c\0\u041e\0\u068a\0\u041e\0\u041e"+ "\0\u06c8\0\u041e\0\u049a\0\u04d8\0\u041e\0\u041e\0\u041e\0\u0706"+ "\0\u0744\0\u041e\0\u041e\0\u0782\0\u041e\0\u041e\0\u041e\0\u07c0"+ - "\0\u07fe\0\u083c\0\u041e\0\u087a\0\u08b8\0\u041e\0\u08f6\0\u0934"+ - "\0\u041e\0\u041e\0\u041e\0\u041e\0\u041e\0\u041e\0\u0972\0\u09b0"+ - "\0\u041e\0\u041e\0\u09ee\0\u041e\0\u041e\0\u041e\0\u041e\0\u0a2c"+ - "\0\u0a6a\0\u041e\0\u041e\0\u0aa8\0\u041e\0\u041e\0\u041e\0\u0ae6"+ - "\0\u041e\0\u041e\0\u041e\0\u041e\0\u0b24\0\u0b62\0\u041e\0\u041e"+ - "\0\u041e\0\u041e\0\u0ba0\0\u041e\0\u0bde\0\u041e\0\u0c1c\0\u0c5a"+ - "\0\u0c98\0\u041e\0\u041e\0\u041e\0\u0cd6\0\u0d14\0\u0d52\0\u041e"+ - "\0\u041e\0\u041e\0\u041e\0\u041e\0\u041e\0\u041e\0\u0d90\0\u0dce"+ + "\0\u07fe\0\u083c\0\u087a\0\u041e\0\u08b8\0\u08f6\0\u041e\0\u0934"+ + "\0\u0972\0\u041e\0\u041e\0\u041e\0\u041e\0\u041e\0\u041e\0\u09b0"+ + "\0\u09ee\0\u041e\0\u041e\0\u0a2c\0\u041e\0\u041e\0\u041e\0\u041e"+ + "\0\u0a6a\0\u0aa8\0\u041e\0\u041e\0\u0ae6\0\u041e\0\u041e\0\u041e"+ + "\0\u0b24\0\u041e\0\u041e\0\u041e\0\u041e\0\u0b62\0\u0ba0\0\u041e"+ + "\0\u041e\0\u041e\0\u041e\0\u0bde\0\u041e\0\u0c1c\0\u041e\0\u0c5a"+ + "\0\u0c98\0\u0cd6\0\u041e\0\u041e\0\u041e\0\u0d14\0\u0d52\0\u0d90"+ + "\0\u041e\0\u041e\0\u041e\0\u041e\0\u041e\0\u041e\0\u041e\0\u0dce"+ "\0\u0e0c\0\u0e4a\0\u041e\0\u0e88\0\u041e\0\u0ec6\0\u041e\0\u041e"+ "\0\u0f04\0\u0f42\0\u0f80\0\u041e\0\u0fbe\0\u0ffc\0\u103a\0\u1078"; @@ -299,59 +299,59 @@ class _RegExLexer implements FlexLexer { "\26\74\1\46\3\74\3\66\1\74\12\66\13\77\1\45"+ "\4\77\1\32\5\77\26\45\1\77\3\45\3\77\1\45"+ "\4\77\1\100\5\77\120\0\1\101\54\0\2\102\14\0"+ - "\1\102\34\0\1\102\32\0\1\103\1\104\5\0\1\105"+ - "\55\0\1\106\1\107\1\110\4\111\1\106\1\112\1\106"+ - "\1\112\1\113\1\106\1\114\1\115\1\106\1\112\5\111"+ - "\2\116\1\117\1\120\3\121\3\122\1\123\2\124\2\125"+ - "\3\126\1\113\1\127\1\130\1\131\1\107\1\132\1\133"+ - "\1\134\2\106\1\115\1\113\1\106\1\115\1\106\1\115"+ - "\6\106\47\0\1\135\27\0\2\45\1\0\2\45\5\0"+ - "\5\45\6\0\32\45\3\0\1\45\13\0\2\46\14\0"+ - "\1\46\34\0\1\46\32\0\1\136\75\0\1\137\1\140"+ - "\5\0\1\105\47\0\1\141\5\0\1\106\1\107\1\110"+ - "\4\111\1\106\3\112\1\113\1\106\1\114\1\115\1\106"+ - "\1\112\5\111\2\116\1\117\1\120\3\121\3\122\1\123"+ - "\2\124\2\125\3\126\1\113\1\127\1\130\1\131\1\107"+ - "\1\132\1\133\1\134\2\106\1\115\1\113\1\106\1\115"+ - "\1\106\1\115\6\106\71\0\1\142\17\0\1\70\12\0"+ - "\26\70\1\0\3\70\3\0\1\70\25\0\1\71\12\0"+ - "\26\71\1\0\3\71\3\0\1\71\13\0\2\74\10\0"+ - "\5\74\6\0\32\74\3\0\1\74\23\0\1\143\70\0"+ - "\1\144\37\0\1\145\13\0\1\146\1\147\6\0\1\150"+ - "\1\0\1\150\1\151\1\152\1\153\1\0\2\102\4\0"+ - "\1\154\7\0\1\102\34\0\1\102\7\0\1\155\22\0"+ - "\1\103\75\0\1\156\1\157\64\0\2\107\51\0\1\107"+ - "\23\0\1\160\51\0\1\160\27\0\1\161\147\0\1\162"+ - "\1\163\14\0\76\164\1\0\2\165\3\0\1\166\20\0"+ - "\2\165\1\0\1\165\4\0\3\165\5\0\2\165\3\0"+ - "\1\165\22\0\2\167\24\0\2\167\1\0\1\167\4\0"+ - "\3\167\5\0\2\167\3\0\1\167\101\0\1\170\1\171"+ - "\25\0\1\172\144\0\1\173\12\0\1\174\75\0\1\175"+ - "\1\176\1\0\5\177\1\0\70\177\1\0\2\200\14\0"+ - "\1\200\34\0\1\200\32\0\1\156\66\0\1\201\51\0"+ - "\1\201\52\0\1\202\45\0\2\203\24\0\2\203\1\0"+ - "\1\203\4\0\3\203\5\0\2\203\3\0\1\203\22\0"+ - "\2\204\4\0\1\205\17\0\2\204\1\0\1\204\4\0"+ - "\3\204\5\0\2\204\3\0\1\204\22\0\2\206\24\0"+ - "\2\206\1\0\1\206\4\0\3\206\5\0\2\206\3\0"+ - "\1\206\21\0\5\177\1\207\70\177\1\0\2\200\4\0"+ - "\1\154\7\0\1\200\34\0\1\200\23\0\1\210\51\0"+ - "\1\210\30\0\1\121\67\0\2\211\4\0\1\203\17\0"+ - "\2\211\1\0\1\211\4\0\3\211\5\0\2\211\3\0"+ - "\1\211\22\0\2\212\24\0\2\212\1\0\1\212\4\0"+ - "\3\212\5\0\2\212\3\0\1\212\22\0\2\213\4\0"+ - "\1\203\17\0\2\213\1\0\1\213\4\0\3\213\5\0"+ - "\2\213\3\0\1\213\22\0\2\214\24\0\2\214\1\0"+ - "\1\214\4\0\3\214\5\0\2\214\3\0\1\214\22\0"+ - "\2\215\4\0\1\203\17\0\2\215\1\0\1\215\4\0"+ - "\3\215\5\0\2\215\3\0\1\215\22\0\2\216\4\0"+ - "\1\203\17\0\2\216\1\0\1\216\4\0\3\216\5\0"+ - "\2\216\3\0\1\216\22\0\2\217\4\0\1\203\17\0"+ - "\2\217\1\0\1\217\4\0\3\217\5\0\2\217\3\0"+ - "\1\217\22\0\2\220\4\0\1\203\17\0\2\220\1\0"+ - "\1\220\4\0\3\220\5\0\2\220\3\0\1\220\22\0"+ - "\2\220\4\0\1\205\17\0\2\220\1\0\1\220\4\0"+ - "\3\220\5\0\2\220\3\0\1\220\21\0"; + "\1\102\34\0\1\102\7\0\1\103\22\0\1\104\1\105"+ + "\5\0\1\106\55\0\1\107\1\110\1\111\4\112\1\107"+ + "\1\113\1\107\1\113\1\114\1\107\1\115\1\116\1\107"+ + "\1\113\5\112\2\117\1\120\1\121\3\122\3\123\1\124"+ + "\2\125\2\126\3\127\1\114\1\130\1\131\1\132\1\110"+ + "\1\133\1\134\1\135\2\107\1\116\1\114\1\107\1\116"+ + "\1\107\1\116\6\107\47\0\1\136\27\0\2\45\1\0"+ + "\2\45\5\0\5\45\6\0\32\45\3\0\1\45\13\0"+ + "\2\46\14\0\1\46\34\0\1\46\32\0\1\137\75\0"+ + "\1\140\1\141\5\0\1\106\47\0\1\142\5\0\1\107"+ + "\1\110\1\111\4\112\1\107\3\113\1\114\1\107\1\115"+ + "\1\116\1\107\1\113\5\112\2\117\1\120\1\121\3\122"+ + "\3\123\1\124\2\125\2\126\3\127\1\114\1\130\1\131"+ + "\1\132\1\110\1\133\1\134\1\135\2\107\1\116\1\114"+ + "\1\107\1\116\1\107\1\116\6\107\71\0\1\143\17\0"+ + "\1\70\12\0\26\70\1\0\3\70\3\0\1\70\25\0"+ + "\1\71\12\0\26\71\1\0\3\71\3\0\1\71\13\0"+ + "\2\74\10\0\5\74\6\0\32\74\3\0\1\74\23\0"+ + "\1\144\70\0\1\145\37\0\1\146\13\0\1\147\1\150"+ + "\6\0\1\151\1\0\1\151\1\152\1\153\1\154\1\0"+ + "\2\102\4\0\1\155\7\0\1\102\34\0\1\102\7\0"+ + "\1\103\12\0\2\156\14\0\1\156\34\0\1\156\32\0"+ + "\1\104\75\0\1\157\1\160\64\0\2\110\51\0\1\110"+ + "\23\0\1\161\51\0\1\161\27\0\1\162\147\0\1\163"+ + "\1\164\14\0\76\165\1\0\2\166\3\0\1\167\20\0"+ + "\2\166\1\0\1\166\4\0\3\166\5\0\2\166\3\0"+ + "\1\166\22\0\2\170\24\0\2\170\1\0\1\170\4\0"+ + "\3\170\5\0\2\170\3\0\1\170\101\0\1\171\1\172"+ + "\25\0\1\173\144\0\1\174\12\0\1\175\75\0\1\176"+ + "\1\177\1\0\5\200\1\0\70\200\1\0\2\156\4\0"+ + "\1\155\7\0\1\156\34\0\1\156\32\0\1\157\66\0"+ + "\1\201\51\0\1\201\52\0\1\202\45\0\2\203\24\0"+ + "\2\203\1\0\1\203\4\0\3\203\5\0\2\203\3\0"+ + "\1\203\22\0\2\204\4\0\1\205\17\0\2\204\1\0"+ + "\1\204\4\0\3\204\5\0\2\204\3\0\1\204\22\0"+ + "\2\206\24\0\2\206\1\0\1\206\4\0\3\206\5\0"+ + "\2\206\3\0\1\206\21\0\5\200\1\207\70\200\2\0"+ + "\1\210\51\0\1\210\30\0\1\122\67\0\2\211\4\0"+ + "\1\203\17\0\2\211\1\0\1\211\4\0\3\211\5\0"+ + "\2\211\3\0\1\211\22\0\2\212\24\0\2\212\1\0"+ + "\1\212\4\0\3\212\5\0\2\212\3\0\1\212\22\0"+ + "\2\213\4\0\1\203\17\0\2\213\1\0\1\213\4\0"+ + "\3\213\5\0\2\213\3\0\1\213\22\0\2\214\24\0"+ + "\2\214\1\0\1\214\4\0\3\214\5\0\2\214\3\0"+ + "\1\214\22\0\2\215\4\0\1\203\17\0\2\215\1\0"+ + "\1\215\4\0\3\215\5\0\2\215\3\0\1\215\22\0"+ + "\2\216\4\0\1\203\17\0\2\216\1\0\1\216\4\0"+ + "\3\216\5\0\2\216\3\0\1\216\22\0\2\217\4\0"+ + "\1\203\17\0\2\217\1\0\1\217\4\0\3\217\5\0"+ + "\2\217\3\0\1\217\22\0\2\220\4\0\1\203\17\0"+ + "\2\220\1\0\1\220\4\0\3\220\5\0\2\220\3\0"+ + "\1\220\22\0\2\220\4\0\1\205\17\0\2\220\1\0"+ + "\1\220\4\0\3\220\5\0\2\220\3\0\1\220\21\0"; private static int [] zzUnpackTrans() { int [] result = new int[4278]; @@ -395,11 +395,11 @@ class _RegExLexer implements FlexLexer { "\13\0\1\1\5\0\2\11\1\1\1\11\3\1\11\11"+ "\1\1\2\11\2\1\3\11\1\1\1\11\1\1\1\11"+ "\1\1\2\11\1\1\1\11\2\1\3\11\2\1\2\11"+ - "\1\1\3\11\2\1\1\0\1\11\1\0\1\1\1\11"+ + "\1\1\3\11\2\1\2\0\1\11\1\0\1\1\1\11"+ "\2\1\6\11\2\1\2\11\1\1\4\11\2\1\2\11"+ "\1\1\3\11\1\0\4\11\1\0\1\1\4\11\1\0"+ "\1\11\1\0\1\11\1\0\1\1\1\0\3\11\3\1"+ - "\7\11\2\0\1\1\1\0\1\11\1\1\1\11\1\1"+ + "\7\11\1\0\1\1\1\0\1\11\1\1\1\11\1\1"+ "\2\11\3\1\1\11\4\1"; private static int [] zzUnpackAttribute() { diff --git a/RegExpSupport/src/org/intellij/lang/regexp/regexp-lexer.flex b/RegExpSupport/src/org/intellij/lang/regexp/regexp-lexer.flex index f738c3e2b9b2..a73673cab62c 100644 --- a/RegExpSupport/src/org/intellij/lang/regexp/regexp-lexer.flex +++ b/RegExpSupport/src/org/intellij/lang/regexp/regexp-lexer.flex @@ -218,9 +218,10 @@ HEX_CHAR=[0-9a-fA-F] /* "{" \d+(,\d*)? "}" */ /* "}" outside counted closure is treated as regular character */ -{LBRACE} / [:digit:]+ {RBRACE} { yypushstate(QUANTIFIER); return RegExpTT.LBRACE; } +{LBRACE} / [:digit:]+ {RBRACE} { yypushstate(QUANTIFIER); return RegExpTT.LBRACE; } {LBRACE} / [:digit:]+ "," [:digit:]+ {RBRACE} { yypushstate(QUANTIFIER); return RegExpTT.LBRACE; } -{LBRACE} { if (yystate() != CLASS2 && !allowDanglingMetacharacters) { yypushstate(QUANTIFIER); return RegExpTT.LBRACE; } return RegExpTT.CHARACTER; } +{LBRACE} / "," [:digit:]+ {RBRACE} { yypushstate(QUANTIFIER); return RegExpTT.LBRACE; } +{LBRACE} { if (yystate() != CLASS2 && !allowDanglingMetacharacters) { yypushstate(QUANTIFIER); return RegExpTT.LBRACE; } return RegExpTT.CHARACTER; } { [:digit:]+ { return RegExpTT.NUMBER; }