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

Method NumberConstant

code.go:540–545  ·  view source on GitHub ↗
(n float64)

Source from the content-addressed store, hash-verified

538}
539
540func (f *function) NumberConstant(n float64) int {
541 if n == 0.0 || math.IsNaN(n) {
542 return f.addConstant(math.Float64bits(n), n)
543 }
544 return f.addConstant(n, n)
545}
546
547func (f *function) CheckStack(n int) {
548 if n += f.freeRegisterCount; n >= maxStack {

Callers 3

dischargeToRegisterMethod · 0.95
forNumericMethod · 0.80

Calls 1

addConstantMethod · 0.95

Tested by

no test coverage detected