pub fn next(state: &mut LuaState, ls: &mut LexState) -> Result<(), LuaError>Expand description
Consume the current token; load the next one from the stream.
If a lookahead token was set, it becomes the current token without re-reading from the stream.
ยงC source
// C: void luaX_next (LexState *ls) {
// ls->lastline = ls->linenumber;
// if (ls->lookahead.token != TK_EOS) {
// ls->t = ls->lookahead;
// ls->lookahead.token = TK_EOS;
// }
// else
// ls->t.token = llex(ls, &ls->t.seminfo);
// }