MCPcopy Index your code
hub / github.com/LissaGreense/GO4SQL / Error

Method Error

parser/errors.go:9–24  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

7}
8
9func (m *SyntaxError) Error() string {
10 var expectingText string
11
12 if len(m.expecting) == 1 {
13 expectingText = m.expecting[0]
14 } else {
15 for i, expected := range m.expecting {
16 expectingText += expected
17 if i != len(m.expecting)-1 {
18 expectingText += ", "
19 }
20 }
21 }
22
23 return "syntax error, expecting: {" + expectingText + "}, got: {" + m.got + "}"
24}
25
26// SyntaxCommandExpectedError - error thrown when there was command that logically should only
27// appear after certain different command, but it wasn't found

Calls

no outgoing calls