-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathmichelson_primitives.go
127 lines (126 loc) · 1.98 KB
/
michelson_primitives.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
package tezosprotocol
const (
// PrimK_parameter and the remaining constants are adapted from Adapted from
// https://gitlab.com/tezos/tezos/blob/master/src%2Fproto_alpha%2Flib_protocol%2Fmichelson_v1_primitives.ml
// They don't follow go's name conventions in order to preserve easy comparison
// with the original ocaml code and easy updates to keep up with protocol changes
// The right order is defined in prim_encoding
PrimK_parameter byte = iota
PrimK_storage
PrimK_code
PrimD_False
PrimD_Elt
PrimD_Left
PrimD_None
PrimD_Pair
PrimD_Right
PrimD_Some
PrimD_True
PrimD_Unit
PrimI_PACK
PrimI_UNPACK
PrimI_BLAKE2B
PrimI_SHA256
PrimI_SHA512
PrimI_ABS
PrimI_ADD
PrimI_AMOUNT
PrimI_AND
PrimI_BALANCE
PrimI_CAR
PrimI_CDR
PrimI_CHECK_SIGNATURE
PrimI_COMPARE
PrimI_CONCAT
PrimI_CONS
PrimI_CREATE_ACCOUNT
PrimI_CREATE_CONTRACT
PrimI_IMPLICIT_ACCOUNT
PrimI_DIP
PrimI_DROP
PrimI_DUP
PrimI_EDIV
PrimI_EMPTY_MAP
PrimI_EMPTY_SET
PrimI_EQ
PrimI_EXEC
PrimI_FAILWITH
PrimI_GE
PrimI_GET
PrimI_GT
PrimI_HASH_KEY
PrimI_IF
PrimI_IF_CONS
PrimI_IF_LEFT
PrimI_IF_NONE
PrimI_INT
PrimI_LAMBDA
PrimI_LE
PrimI_LEFT
PrimI_LOOP
PrimI_LSL
PrimI_LSR
PrimI_LT
PrimI_MAP
PrimI_MEM
PrimI_MUL
PrimI_NEG
PrimI_NEQ
PrimI_NIL
PrimI_NONE
PrimI_NOT
PrimI_NOW
PrimI_OR
PrimI_PAIR
PrimI_PUSH
PrimI_RIGHT
PrimI_SIZE
PrimI_SOME
PrimI_SOURCE
PrimI_SENDER
PrimI_SELF
PrimI_STEPS_TO_QUOTA
PrimI_SUB
PrimI_SWAP
PrimI_TRANSFER_TOKENS
PrimI_SET_DELEGATE
PrimI_UNIT
PrimI_UPDATE
PrimI_XOR
PrimI_ITER
PrimI_LOOP_LEFT
PrimI_ADDRESS
PrimI_CONTRACT
PrimI_ISNAT
PrimI_CAST
PrimI_RENAME
PrimT_bool
PrimT_contract
PrimT_int
PrimT_key
PrimT_key_hash
PrimT_lambda
PrimT_list
PrimT_map
PrimT_big_map
PrimT_nat
PrimT_option
PrimT_or
PrimT_pair
PrimT_set
PrimT_signature
PrimT_string
PrimT_bytes
PrimT_mutez
PrimT_timestamp
PrimT_unit
PrimT_operation
PrimT_address
PrimI_SLICE
PrimI_DIG
PrimI_DUG
PrimI_EMPTY_BIG_MAP
PrimI_APPLY
PrimT_chain_id
PrimI_CHAIN_ID
)