Пример #1
0
 @SuppressWarnings("rawtypes")
 private Token accept(Class clazz) {
   if (this.peek().getClass().equals(clazz)) {
     return lexer.advance();
   }
   return null;
 }
Пример #2
0
 private Token nextToken() {
   return lexer.advance();
 }
Пример #3
0
 private void skip(int n) {
   while (n > 0) {
     lexer.advance();
     n = n - 1;
   }
 }