(from, to *gotoLabelDesc, index int)
| 456 | } |
| 457 | |
| 458 | func (fc *funcContext) ResolveGoto(from, to *gotoLabelDesc, index int) { |
| 459 | if from.NumActiveLocalVars < to.NumActiveLocalVars { |
| 460 | varName := fc.Block.LocalVars.Names()[len(fc.Block.LocalVars.Names())-1] |
| 461 | raiseCompileError(fc, to.Line+1, "<goto %s> at line %d jumps into the scope of local '%s'", to.Name, from.Line, varName) |
| 462 | } |
| 463 | fc.Code.SetSbx(from.Pc, to.Id) |
| 464 | delete(fc.unresolvedGotos, index) |
| 465 | } |
| 466 | |
| 467 | func (fc *funcContext) FindLabel(block *codeBlock, gotoLabel *gotoLabelDesc, i int) bool { |
| 468 | target := block.GetLabel(gotoLabel.Name) |
no test coverage detected