MCPcopy Create free account
hub / github.com/dop251/goja / Error

Method Error

parser/error.go:59–70  ·  view source on GitHub ↗

FIXME Should this be "SyntaxError"?

()

Source from the content-addressed store, hash-verified

57// FIXME Should this be "SyntaxError"?
58
59func (self Error) Error() string {
60 filename := self.Position.Filename
61 if filename == "" {
62 filename = "(anonymous)"
63 }
64 return fmt.Sprintf("%s: Line %d:%d %s",
65 filename,
66 self.Position.Line,
67 self.Position.Column,
68 self.Message,
69 )
70}
71
72func (self *_parser) error(place interface{}, msg string, msgValues ...interface{}) *Error {
73 idx := file.Idx(0)

Callers 3

ErrorMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected