forked from quasilyte/gogrep
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathoperation_string.go
154 lines (148 loc) · 6.08 KB
/
operation_string.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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
// Code generated by "stringer -type=operation -trimprefix=op"; DO NOT EDIT.
package gogrep
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[opInvalid-0]
_ = x[opNode-1]
_ = x[opNamedNode-2]
_ = x[opNodeSeq-3]
_ = x[opNamedNodeSeq-4]
_ = x[opOptNode-5]
_ = x[opNamedOptNode-6]
_ = x[opFieldNode-7]
_ = x[opNamedFieldNode-8]
_ = x[opMultiStmt-9]
_ = x[opMultiExpr-10]
_ = x[opMultiDecl-11]
_ = x[opEnd-12]
_ = x[opBasicLit-13]
_ = x[opStrictIntLit-14]
_ = x[opStrictFloatLit-15]
_ = x[opStrictCharLit-16]
_ = x[opStrictStringLit-17]
_ = x[opStrictComplexLit-18]
_ = x[opIdent-19]
_ = x[opPkg-20]
_ = x[opIndexExpr-21]
_ = x[opIndexListExpr-22]
_ = x[opSliceExpr-23]
_ = x[opSliceFromExpr-24]
_ = x[opSliceToExpr-25]
_ = x[opSliceFromToExpr-26]
_ = x[opSliceToCapExpr-27]
_ = x[opSliceFromToCapExpr-28]
_ = x[opFuncLit-29]
_ = x[opCompositeLit-30]
_ = x[opTypedCompositeLit-31]
_ = x[opSimpleSelectorExpr-32]
_ = x[opSelectorExpr-33]
_ = x[opTypeAssertExpr-34]
_ = x[opTypeSwitchAssertExpr-35]
_ = x[opStructType-36]
_ = x[opInterfaceType-37]
_ = x[opEfaceType-38]
_ = x[opVoidFuncType-39]
_ = x[opGenericVoidFuncType-40]
_ = x[opFuncType-41]
_ = x[opGenericFuncType-42]
_ = x[opArrayType-43]
_ = x[opSliceType-44]
_ = x[opMapType-45]
_ = x[opChanType-46]
_ = x[opKeyValueExpr-47]
_ = x[opEllipsis-48]
_ = x[opTypedEllipsis-49]
_ = x[opStarExpr-50]
_ = x[opUnaryExpr-51]
_ = x[opBinaryExpr-52]
_ = x[opParenExpr-53]
_ = x[opArgList-54]
_ = x[opSimpleArgList-55]
_ = x[opVariadicCallExpr-56]
_ = x[opNonVariadicCallExpr-57]
_ = x[opMaybeVariadicCallExpr-58]
_ = x[opCallExpr-59]
_ = x[opAssignStmt-60]
_ = x[opMultiAssignStmt-61]
_ = x[opBranchStmt-62]
_ = x[opSimpleLabeledBranchStmt-63]
_ = x[opLabeledBranchStmt-64]
_ = x[opSimpleLabeledStmt-65]
_ = x[opLabeledStmt-66]
_ = x[opBlockStmt-67]
_ = x[opExprStmt-68]
_ = x[opGoStmt-69]
_ = x[opDeferStmt-70]
_ = x[opSendStmt-71]
_ = x[opEmptyStmt-72]
_ = x[opIncDecStmt-73]
_ = x[opReturnStmt-74]
_ = x[opIfStmt-75]
_ = x[opIfInitStmt-76]
_ = x[opIfElseStmt-77]
_ = x[opIfInitElseStmt-78]
_ = x[opIfNamedOptStmt-79]
_ = x[opIfNamedOptElseStmt-80]
_ = x[opSwitchStmt-81]
_ = x[opSwitchTagStmt-82]
_ = x[opSwitchInitStmt-83]
_ = x[opSwitchInitTagStmt-84]
_ = x[opSelectStmt-85]
_ = x[opTypeSwitchStmt-86]
_ = x[opTypeSwitchInitStmt-87]
_ = x[opCaseClause-88]
_ = x[opDefaultCaseClause-89]
_ = x[opCommClause-90]
_ = x[opDefaultCommClause-91]
_ = x[opForStmt-92]
_ = x[opForPostStmt-93]
_ = x[opForCondStmt-94]
_ = x[opForCondPostStmt-95]
_ = x[opForInitStmt-96]
_ = x[opForInitPostStmt-97]
_ = x[opForInitCondStmt-98]
_ = x[opForInitCondPostStmt-99]
_ = x[opRangeStmt-100]
_ = x[opRangeKeyStmt-101]
_ = x[opRangeKeyValueStmt-102]
_ = x[opRangeClause-103]
_ = x[opRangeHeader-104]
_ = x[opRangeKeyHeader-105]
_ = x[opRangeKeyValueHeader-106]
_ = x[opFieldList-107]
_ = x[opUnnamedField-108]
_ = x[opSimpleField-109]
_ = x[opField-110]
_ = x[opMultiField-111]
_ = x[opValueSpec-112]
_ = x[opValueInitSpec-113]
_ = x[opTypedValueInitSpec-114]
_ = x[opTypedValueSpec-115]
_ = x[opSimpleTypeSpec-116]
_ = x[opTypeSpec-117]
_ = x[opGenericTypeSpec-118]
_ = x[opTypeAliasSpec-119]
_ = x[opSimpleFuncDecl-120]
_ = x[opFuncDecl-121]
_ = x[opMethodDecl-122]
_ = x[opFuncProtoDecl-123]
_ = x[opMethodProtoDecl-124]
_ = x[opDeclStmt-125]
_ = x[opConstDecl-126]
_ = x[opVarDecl-127]
_ = x[opTypeDecl-128]
_ = x[opAnyImportDecl-129]
_ = x[opImportDecl-130]
_ = x[opEmptyPackage-131]
}
const _operation_name = "InvalidNodeNamedNodeNodeSeqNamedNodeSeqOptNodeNamedOptNodeFieldNodeNamedFieldNodeMultiStmtMultiExprMultiDeclEndBasicLitStrictIntLitStrictFloatLitStrictCharLitStrictStringLitStrictComplexLitIdentPkgIndexExprIndexListExprSliceExprSliceFromExprSliceToExprSliceFromToExprSliceToCapExprSliceFromToCapExprFuncLitCompositeLitTypedCompositeLitSimpleSelectorExprSelectorExprTypeAssertExprTypeSwitchAssertExprStructTypeInterfaceTypeEfaceTypeVoidFuncTypeGenericVoidFuncTypeFuncTypeGenericFuncTypeArrayTypeSliceTypeMapTypeChanTypeKeyValueExprEllipsisTypedEllipsisStarExprUnaryExprBinaryExprParenExprArgListSimpleArgListVariadicCallExprNonVariadicCallExprMaybeVariadicCallExprCallExprAssignStmtMultiAssignStmtBranchStmtSimpleLabeledBranchStmtLabeledBranchStmtSimpleLabeledStmtLabeledStmtBlockStmtExprStmtGoStmtDeferStmtSendStmtEmptyStmtIncDecStmtReturnStmtIfStmtIfInitStmtIfElseStmtIfInitElseStmtIfNamedOptStmtIfNamedOptElseStmtSwitchStmtSwitchTagStmtSwitchInitStmtSwitchInitTagStmtSelectStmtTypeSwitchStmtTypeSwitchInitStmtCaseClauseDefaultCaseClauseCommClauseDefaultCommClauseForStmtForPostStmtForCondStmtForCondPostStmtForInitStmtForInitPostStmtForInitCondStmtForInitCondPostStmtRangeStmtRangeKeyStmtRangeKeyValueStmtRangeClauseRangeHeaderRangeKeyHeaderRangeKeyValueHeaderFieldListUnnamedFieldSimpleFieldFieldMultiFieldValueSpecValueInitSpecTypedValueInitSpecTypedValueSpecSimpleTypeSpecTypeSpecGenericTypeSpecTypeAliasSpecSimpleFuncDeclFuncDeclMethodDeclFuncProtoDeclMethodProtoDeclDeclStmtConstDeclVarDeclTypeDeclAnyImportDeclImportDeclEmptyPackage"
var _operation_index = [...]uint16{0, 7, 11, 20, 27, 39, 46, 58, 67, 81, 90, 99, 108, 111, 119, 131, 145, 158, 173, 189, 194, 197, 206, 219, 228, 241, 252, 267, 281, 299, 306, 318, 335, 353, 365, 379, 399, 409, 422, 431, 443, 462, 470, 485, 494, 503, 510, 518, 530, 538, 551, 559, 568, 578, 587, 594, 607, 623, 642, 663, 671, 681, 696, 706, 729, 746, 763, 774, 783, 791, 797, 806, 814, 823, 833, 843, 849, 859, 869, 883, 897, 915, 925, 938, 952, 969, 979, 993, 1011, 1021, 1038, 1048, 1065, 1072, 1083, 1094, 1109, 1120, 1135, 1150, 1169, 1178, 1190, 1207, 1218, 1229, 1243, 1262, 1271, 1283, 1294, 1299, 1309, 1318, 1331, 1349, 1363, 1377, 1385, 1400, 1413, 1427, 1435, 1445, 1458, 1473, 1481, 1490, 1497, 1505, 1518, 1528, 1540}
func (i operation) String() string {
if i >= operation(len(_operation_index)-1) {
return "operation(" + strconv.FormatInt(int64(i), 10) + ")"
}
return _operation_name[_operation_index[i]:_operation_index[i+1]]
}