This repository has been archived by the owner on Aug 23, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstringer.go
114 lines (102 loc) · 3.45 KB
/
stringer.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
// Code generated by "stringer -type=TokenType,astTokenType,opcode -output stringer.go"; DO NOT EDIT.
package goal
import "strconv"
func _() {
// An "invalid array index" compiler error signifies that the constant values have changed.
// Re-run the stringer command to generate them again.
var x [1]struct{}
_ = x[NONE-0]
_ = x[EOF-1]
_ = x[ERROR-2]
_ = x[ADVERB-3]
_ = x[DYAD-4]
_ = x[DYADASSIGN-5]
_ = x[IDENT-6]
_ = x[LEFTBRACE-7]
_ = x[LEFTBRACKET-8]
_ = x[LEFTBRACKETS-9]
_ = x[LEFTPAREN-10]
_ = x[NEWLINE-11]
_ = x[NUMBER-12]
_ = x[MONAD-13]
_ = x[REGEXP-14]
_ = x[RIGHTBRACE-15]
_ = x[RIGHTBRACKET-16]
_ = x[RIGHTPAREN-17]
_ = x[SEMICOLON-18]
_ = x[SADVERB-19]
_ = x[STRING-20]
_ = x[QQSTART-21]
_ = x[QQEND-22]
}
const _TokenType_name = "NONEEOFERRORADVERBDYADDYADASSIGNIDENTLEFTBRACELEFTBRACKETLEFTBRACKETSLEFTPARENNEWLINENUMBERMONADREGEXPRIGHTBRACERIGHTBRACKETRIGHTPARENSEMICOLONSADVERBSTRINGQQSTARTQQEND"
var _TokenType_index = [...]uint8{0, 4, 7, 12, 18, 22, 32, 37, 46, 57, 69, 78, 85, 91, 96, 102, 112, 124, 134, 143, 150, 156, 163, 168}
func (i TokenType) String() string {
if i < 0 || i >= TokenType(len(_TokenType_index)-1) {
return "TokenType(" + strconv.FormatInt(int64(i), 10) + ")"
}
return _TokenType_name[_TokenType_index[i]:_TokenType_index[i+1]]
}
func _() {
// An "invalid array index" compiler error signifies that the constant values have changed.
// Re-run the stringer command to generate them again.
var x [1]struct{}
_ = x[astNUMBER-0]
_ = x[astSTRING-1]
_ = x[astIDENT-2]
_ = x[astMONAD-3]
_ = x[astDYAD-4]
_ = x[astADVERB-5]
_ = x[astREGEXP-6]
_ = x[astEMPTYLIST-7]
}
const _astTokenType_name = "astNUMBERastSTRINGastIDENTastMONADastDYADastADVERBastREGEXPastEMPTYLIST"
var _astTokenType_index = [...]uint8{0, 9, 18, 26, 34, 41, 50, 59, 71}
func (i astTokenType) String() string {
if i < 0 || i >= astTokenType(len(_astTokenType_index)-1) {
return "astTokenType(" + strconv.FormatInt(int64(i), 10) + ")"
}
return _astTokenType_name[_astTokenType_index[i]:_astTokenType_index[i+1]]
}
func _() {
// An "invalid array index" compiler error signifies that the constant values have changed.
// Re-run the stringer command to generate them again.
var x [1]struct{}
_ = x[opNop-0]
_ = x[opNil-1]
_ = x[opConst-2]
_ = x[opInt-3]
_ = x[opVariadic-4]
_ = x[opLambda-5]
_ = x[opLocal-6]
_ = x[opLocalLast-7]
_ = x[opGlobal-8]
_ = x[opGlobalLast-9]
_ = x[opAssignLocal-10]
_ = x[opAssignGlobal-11]
_ = x[opListAssignLocal-12]
_ = x[opListAssignGlobal-13]
_ = x[opApply-14]
_ = x[opApplyV-15]
_ = x[opApplyGlobal-16]
_ = x[opDerive-17]
_ = x[opApply2-18]
_ = x[opApply2V-19]
_ = x[opApplyN-20]
_ = x[opApplyNGlobal-21]
_ = x[opApplyNV-22]
_ = x[opDrop-23]
_ = x[opJump-24]
_ = x[opJumpFalse-25]
_ = x[opJumpTrue-26]
_ = x[opReturn-27]
_ = x[opTry-28]
}
const _opcode_name = "opNopopNilopConstopIntopVariadicopLambdaopLocalopLocalLastopGlobalopGlobalLastopAssignLocalopAssignGlobalopListAssignLocalopListAssignGlobalopApplyopApplyVopApplyGlobalopDeriveopApply2opApply2VopApplyNopApplyNGlobalopApplyNVopDropopJumpopJumpFalseopJumpTrueopReturnopTry"
var _opcode_index = [...]uint16{0, 5, 10, 17, 22, 32, 40, 47, 58, 66, 78, 91, 105, 122, 140, 147, 155, 168, 176, 184, 193, 201, 215, 224, 230, 236, 247, 257, 265, 270}
func (i opcode) String() string {
if i < 0 || i >= opcode(len(_opcode_index)-1) {
return "opcode(" + strconv.FormatInt(int64(i), 10) + ")"
}
return _opcode_name[_opcode_index[i]:_opcode_index[i+1]]
}