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

Function Errorf

auxiliary.go:209–214  ·  view source on GitHub ↗

Errorf raises an error. The error message format is given by format plus any extra arguments, following the same rules as PushFString. It also adds at the beginning of the message the file name and the line number where the error occurred, if this information is available. This function never retur

(l *State, format string, a ...interface{})

Source from the content-addressed store, hash-verified

207// lua.Errorf(l, args)
208// panic("unreachable")
209func Errorf(l *State, format string, a ...interface{}) {
210 Where(l, 1)
211 l.PushFString(format, a...)
212 l.Concat(2)
213 l.Error()
214}
215
216// ToStringMeta converts any Lua value at the given index to a Go string in a
217// reasonable format. The resulting string is pushed onto the stack and also

Callers 15

clockFunction · 0.85
fieldArgumentsFunction · 0.85
ReadMethod · 0.85
base.goFile · 0.85
scanFormatFunction · 0.85
formatHelperFunction · 0.85
string.goFile · 0.85
TestErrorfFunction · 0.85
table.goFile · 0.85
toFileFunction · 0.85
ioFileFunction · 0.85

Calls 4

WhereFunction · 0.85
PushFStringMethod · 0.80
ConcatMethod · 0.80
ErrorMethod · 0.45

Tested by 2

TestErrorfFunction · 0.68