diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2023-06-22 11:41:48 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2023-06-22 11:41:48 -0300 |
commit | ab6a94952215b1f66436d8eeebded1dad9fa5409 (patch) | |
tree | ba66254537defc76602ce351d962b899ddfe1b29 /lparser.c | |
parent | 86e8039a72646cd9192fd08a6f1771c90b872ff6 (diff) | |
parent | ea39042e13645f63713425c05cc9ee4cfdcf0a40 (diff) | |
download | lua-ab6a94952215b1f66436d8eeebded1dad9fa5409.tar.gz lua-ab6a94952215b1f66436d8eeebded1dad9fa5409.tar.bz2 lua-ab6a94952215b1f66436d8eeebded1dad9fa5409.zip |
Merge branch 'master' into nextversion
Diffstat (limited to 'lparser.c')
-rw-r--r-- | lparser.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -529,12 +529,12 @@ static l_noret jumpscopeerror (LexState *ls, Labeldesc *gt) { | |||
529 | 529 | ||
530 | /* | 530 | /* |
531 | ** Solves the goto at index 'g' to given 'label' and removes it | 531 | ** Solves the goto at index 'g' to given 'label' and removes it |
532 | ** from the list of pending goto's. | 532 | ** from the list of pending gotos. |
533 | ** If it jumps into the scope of some variable, raises an error. | 533 | ** If it jumps into the scope of some variable, raises an error. |
534 | */ | 534 | */ |
535 | static void solvegoto (LexState *ls, int g, Labeldesc *label) { | 535 | static void solvegoto (LexState *ls, int g, Labeldesc *label) { |
536 | int i; | 536 | int i; |
537 | Labellist *gl = &ls->dyd->gt; /* list of goto's */ | 537 | Labellist *gl = &ls->dyd->gt; /* list of gotos */ |
538 | Labeldesc *gt = &gl->arr[g]; /* goto to be resolved */ | 538 | Labeldesc *gt = &gl->arr[g]; /* goto to be resolved */ |
539 | lua_assert(eqstr(gt->name, label->name)); | 539 | lua_assert(eqstr(gt->name, label->name)); |
540 | if (l_unlikely(gt->nactvar < label->nactvar)) /* enter some scope? */ | 540 | if (l_unlikely(gt->nactvar < label->nactvar)) /* enter some scope? */ |
@@ -588,7 +588,7 @@ static int newgotoentry (LexState *ls, TString *name, int line, int pc) { | |||
588 | /* | 588 | /* |
589 | ** Solves forward jumps. Check whether new label 'lb' matches any | 589 | ** Solves forward jumps. Check whether new label 'lb' matches any |
590 | ** pending gotos in current block and solves them. Return true | 590 | ** pending gotos in current block and solves them. Return true |
591 | ** if any of the goto's need to close upvalues. | 591 | ** if any of the gotos need to close upvalues. |
592 | */ | 592 | */ |
593 | static int solvegotos (LexState *ls, Labeldesc *lb) { | 593 | static int solvegotos (LexState *ls, Labeldesc *lb) { |
594 | Labellist *gl = &ls->dyd->gt; | 594 | Labellist *gl = &ls->dyd->gt; |
@@ -609,7 +609,7 @@ static int solvegotos (LexState *ls, Labeldesc *lb) { | |||
609 | /* | 609 | /* |
610 | ** Create a new label with the given 'name' at the given 'line'. | 610 | ** Create a new label with the given 'name' at the given 'line'. |
611 | ** 'last' tells whether label is the last non-op statement in its | 611 | ** 'last' tells whether label is the last non-op statement in its |
612 | ** block. Solves all pending goto's to this new label and adds | 612 | ** block. Solves all pending gotos to this new label and adds |
613 | ** a close instruction if necessary. | 613 | ** a close instruction if necessary. |
614 | ** Returns true iff it added a close instruction. | 614 | ** Returns true iff it added a close instruction. |
615 | */ | 615 | */ |