MCPcopy
hub / github.com/expr-lang/expr / patchJump

Method patchJump

compiler/compiler.go:207–210  ·  view source on GitHub ↗
(placeholder int)

Source from the content-addressed store, hash-verified

205}
206
207func (c *compiler) patchJump(placeholder int) {
208 offset := len(c.bytecode) - placeholder
209 c.arguments[placeholder-1] = offset
210}
211
212func (c *compiler) calcBackwardJump(to int) int {
213 return len(c.bytecode) + 1 - to

Callers 7

BinaryNodeMethod · 0.95
ChainNodeMethod · 0.95
BuiltinNodeMethod · 0.95
emitCondMethod · 0.95
emitLoopMethod · 0.95
emitLoopBackwardsMethod · 0.95
ConditionalNodeMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected