| 127 | |
| 128 | |
| 129 | static void inclinenumber (LexState *ls) { |
| 130 | int old = ls->current; |
| 131 | lua_assert(currIsNewline(ls)); |
| 132 | next(ls); /* skip `\n' or `\r' */ |
| 133 | if (currIsNewline(ls) && ls->current != old) |
| 134 | next(ls); /* skip `\n\r' or `\r\n' */ |
| 135 | if (++ls->linenumber >= MAX_INT) |
| 136 | luaX_syntaxerror(ls, "chunk has too many lines"); |
| 137 | } |
| 138 | |
| 139 | |
| 140 | void luaX_setinput (lua_State *L, LexState *ls, ZIO *z, TString *source) { |
no test coverage detected