| 581 | |
| 582 | |
| 583 | void luaX_next(LexState *ls) { |
| 584 | ls->lastline = ls->linenumber; |
| 585 | if (ls->lookahead.token != TK_EOS) { /* is there a look-ahead token? */ |
| 586 | ls->t = ls->lookahead; /* use this one */ |
| 587 | ls->lookahead.token = TK_EOS; /* and discharge it */ |
| 588 | } |
| 589 | else |
| 590 | ls->t.token = llex(ls, &ls->t.seminfo); /* read next token */ |
| 591 | } |
| 592 | |
| 593 | |
| 594 | int luaX_lookahead(LexState *ls) { |