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
#[derive(Clone)]
pub enum Term {
Assert(Box<Term>),
Assignment(Box<Term>,Box<Term>),
Goto(String),
IfGoto(Box<Term>,String),
Label(String),
Succeed(Vec<Term>),
Revert(Vec<Term>),
Fail,
Stop,
Binary(BinOp,Box<Term>,Box<Term>),
ArrayAccess(Box<Term>,Box<Term>),
MemoryAccess(Region),
Int(Vec<u8>),
Hex(Vec<u8>),
}
#[derive(Copy,Clone,PartialEq,Debug)]
pub enum BinOp {
Add,
Subtract,
Divide,
Multiply,
Remainder,
Equals,
NotEquals,
LessThan,
LessThanOrEquals,
GreaterThan,
GreaterThanOrEquals,
LogicalAnd,
LogicalOr
}
#[derive(Copy,Clone,PartialEq,Debug)]
pub enum Region {
Memory,
Storage,
CallData
}