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

Function LengthEx

auxiliary.go:548–556  ·  view source on GitHub ↗
(l *State, index int)

Source from the content-addressed store, hash-verified

546}
547
548func LengthEx(l *State, index int) int {
549 l.Length(index)
550 if length, ok := l.ToInteger(-1); ok {
551 l.Pop(1)
552 return length
553 }
554 Errorf(l, "object length is not a number")
555 panic("unreachable")
556}
557
558// FileResult produces the return values for file-related functions in the standard
559// library (io.open, os.rename, file:seek, etc.).

Callers 2

TestTableNextFunction · 0.85
table.goFile · 0.85

Calls 4

ErrorfFunction · 0.85
LengthMethod · 0.80
ToIntegerMethod · 0.80
PopMethod · 0.80

Tested by 1

TestTableNextFunction · 0.68