Issue #49. Fixed parsing multiple html attributes.

This commit is contained in:
Baratali Izmailov 2014-10-22 19:48:00 +04:00 committed by Roman Ivanov
parent d1a7c16076
commit 5650fc1fcd
1 changed files with 4 additions and 4 deletions

View File

@ -382,10 +382,10 @@ mode htmlAttr;
Leading_asterisk7: LEADING_ASTERISK -> type(LEADING_ASTERISK);
NewLine8: NEWLINE -> type(NEWLINE);
ATTR_VALUE : '"' ~[<"]* '"' {attributeCatched=true;}
| '\'' ~[<']* '\'' {attributeCatched=true;}
| ( '-' | '+' | DIGIT)+ {attributeCatched=true;}
| (~[> \t\n/] | SlashInAttr)+ {attributeCatched=true;}
ATTR_VALUE : '"' ~[<"]* '"' {!attributeCatched}? {attributeCatched=true;}
| '\'' ~[<']* '\'' {!attributeCatched}? {attributeCatched=true;}
| ( '-' | '+' | DIGIT)+ {!attributeCatched}? {attributeCatched=true;}
| (~[> \t\n/] | SlashInAttr)+ {!attributeCatched}? {attributeCatched=true;}
;
fragment SlashInAttr: '/' {_input.LA(1) != '>'}?;