()
| 587 | } |
| 588 | |
| 589 | Token COMMENT() { |
| 590 | match('!'); |
| 591 | while ( !(c=='!' && input.LA(2)==delimiterStopChar) ) { |
| 592 | if ( c==EOF ) { |
| 593 | RecognitionException re = new MismatchedTokenException((int)'!', input); |
| 594 | re.line = input.getLine(); |
| 595 | re.charPositionInLine = input.getCharPositionInLine(); |
| 596 | errMgr.lexerError(input.getSourceName(), "Nonterminated comment starting at "+startLine+":"+startCharPositionInLine+": '!"+delimiterStopChar+"' missing", templateToken, re); |
| 597 | break; |
| 598 | } |
| 599 | consume(); |
| 600 | } |
| 601 | consume(); |
| 602 | consume(); // grab !> |
| 603 | return newToken(COMMENT); |
| 604 | } |
| 605 | |
| 606 | void LINEBREAK() { |
| 607 | match('\\'); // only kill 2nd \ as ESCAPE() kills first one |
no test coverage detected