(TokenType target)
| 609 | } |
| 610 | |
| 611 | public Token nextOrFail(TokenType target) throws ParseException { |
| 612 | Token tok = nextToken(); |
| 613 | if (tok.type.equals(target)) { |
| 614 | return tok; |
| 615 | } |
| 616 | throw error(line, "mismatch type; looking for " + target); |
| 617 | } |
| 618 | |
| 619 | void pushback(Token t) { |
| 620 | pushBack.addFirst(t); |
no test coverage detected