MCPcopy Create free account
hub / github.com/Shopify/go-lua / setUpValue

Method setUpValue

stack.go:48–55  ·  view source on GitHub ↗
(i int, v value)

Source from the content-addressed store, hash-verified

46}
47
48func (c *luaClosure) setUpValue(i int, v value) {
49 uv := c.upValues[i]
50 if home, ok := uv.home.(stackLocation); ok {
51 home.state.stack[home.index] = v
52 } else {
53 uv.home = v
54 }
55}
56
57func (c *luaClosure) upValueCount() int { return len(c.upValues) }
58func (c *goClosure) upValue(i int) value { return c.upValues[i] }

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected