MCPcopy Index your code
hub / github.com/Shopify/go-lua / fixJump

Method fixJump

code.go:401–409  ·  view source on GitHub ↗
(pc, dest int)

Source from the content-addressed store, hash-verified

399}
400
401func (f *function) fixJump(pc, dest int) {
402 f.assert(f.isJumpListWalkable(pc))
403 f.assert(dest != noJump)
404 offset := dest - (pc + 1)
405 if abs(offset) > maxArgSBx {
406 f.p.syntaxError("control structure too long")
407 }
408 f.f.code[pc].setSBx(offset)
409}
410
411func (f *function) Label() int {
412 f.lastTarget = len(f.f.code)

Callers 2

patchListHelperMethod · 0.95
ConcatenateMethod · 0.95

Calls 5

assertMethod · 0.95
isJumpListWalkableMethod · 0.95
absFunction · 0.85
syntaxErrorMethod · 0.80
setSBxMethod · 0.80

Tested by

no test coverage detected