1
2
3
4
5 package noder
6
7 import "internal/pkgbits"
8
9
10 type codeStmt int
11
12 func (c codeStmt) Marker() pkgbits.SyncMarker { return pkgbits.SyncStmt1 }
13 func (c codeStmt) Value() int { return int(c) }
14
15 const (
16 stmtEnd codeStmt = iota
17 stmtLabel
18 stmtBlock
19 stmtExpr
20 stmtSend
21 stmtAssign
22 stmtAssignOp
23 stmtIncDec
24 stmtBranch
25 stmtCall
26 stmtReturn
27 stmtIf
28 stmtFor
29 stmtSwitch
30 stmtSelect
31 )
32
33
34 type codeExpr int
35
36 func (c codeExpr) Marker() pkgbits.SyncMarker { return pkgbits.SyncExpr }
37 func (c codeExpr) Value() int { return int(c) }
38
39
40 const (
41 exprConst codeExpr = iota
42 exprLocal
43 exprGlobal
44 exprCompLit
45 exprFuncLit
46 exprFieldVal
47 exprMethodVal
48 exprMethodExpr
49 exprIndex
50 exprSlice
51 exprAssert
52 exprUnaryOp
53 exprBinaryOp
54 exprCall
55 exprConvert
56 exprNew
57 exprMake
58 exprSizeof
59 exprAlignof
60 exprOffsetof
61 exprZero
62 exprFuncInst
63 exprRecv
64 exprReshape
65 exprRuntimeBuiltin
66 )
67
68 type codeAssign int
69
70 func (c codeAssign) Marker() pkgbits.SyncMarker { return pkgbits.SyncAssign }
71 func (c codeAssign) Value() int { return int(c) }
72
73 const (
74 assignBlank codeAssign = iota
75 assignDef
76 assignExpr
77 )
78
79
80 type codeDecl int
81
82 func (c codeDecl) Marker() pkgbits.SyncMarker { return pkgbits.SyncDecl }
83 func (c codeDecl) Value() int { return int(c) }
84
85 const (
86 declEnd codeDecl = iota
87 declFunc
88 declMethod
89 declVar
90 declOther
91 )
92
View as plain text