MCPcopy Create free account
hub / github.com/DFHack/dfhack / undefgoto

Function undefgoto

depends/lua/src/lparser.c:464–470  ·  view source on GitHub ↗

** generates an error for an undefined 'goto'; choose appropriate ** message when label name is a reserved word (which can only be 'break') */

Source from the content-addressed store, hash-verified

462** message when label name is a reserved word (which can only be 'break')
463*/
464static l_noret undefgoto (LexState *ls, Labeldesc *gt) {
465 const char *msg = isreserved(gt->name)
466 ? "<%s> at line %d not inside a loop"
467 : "no visible label '%s' for <goto> at line %d";
468 msg = luaO_pushfstring(ls->L, msg, getstr(gt->name), gt->line);
469 semerror(ls, msg);
470}
471
472
473static void leaveblock (FuncState *fs) {

Callers 1

leaveblockFunction · 0.85

Calls 2

luaO_pushfstringFunction · 0.85
semerrorFunction · 0.85

Tested by

no test coverage detected