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
use crate::Hash;
use std::cmp;
use std::hash;
#[derive(Debug)]
pub struct StaticType {
pub name: &'static str,
pub hash: Hash,
}
impl cmp::PartialEq for &'static StaticType {
fn eq(&self, other: &Self) -> bool {
self.hash == other.hash
}
}
impl cmp::Eq for &'static StaticType {}
impl hash::Hash for &'static StaticType {
fn hash<H: hash::Hasher>(&self, state: &mut H) {
self.hash.hash(state)
}
}
pub static UNIT_TYPE: &StaticType = &StaticType {
name: "unit",
hash: Hash::new(0x9de148b05752dbb3),
};
pub static BYTE_TYPE: &StaticType = &StaticType {
name: "byte",
hash: Hash::new(0x190cacf7c7187189),
};
pub static BOOL_TYPE: &StaticType = &StaticType {
name: "bool",
hash: Hash::new(0xbe6bff4422d0c759),
};
pub static CHAR_TYPE: &StaticType = &StaticType {
name: "char",
hash: Hash::new(0xc56a31d061187c8b),
};
pub static INTEGER_TYPE: &StaticType = &StaticType {
name: "integer",
hash: Hash::new(0xbb378867da3981e2),
};
pub static FLOAT_TYPE: &StaticType = &StaticType {
name: "float",
hash: Hash::new(0x13e40c27462ed8fc),
};
pub static STRING_TYPE: &StaticType = &StaticType {
name: "String",
hash: Hash::new(0x823ede4114ff8de6),
};
pub static BYTES_TYPE: &StaticType = &StaticType {
name: "Bytes",
hash: Hash::new(0x957fa73126817683),
};
pub static VEC_TYPE: &StaticType = &StaticType {
name: "Vec",
hash: Hash::new(0x6c129752545b4223),
};
pub static TUPLE_TYPE: &StaticType = &StaticType {
name: "Tuple",
hash: Hash::new(0x6da74f62cfa5cc1f),
};
pub static OBJECT_TYPE: &StaticType = &StaticType {
name: "Object",
hash: Hash::new(0x65f4e1cf10b1f34c),
};
pub static FUTURE_TYPE: &StaticType = &StaticType {
name: "Future",
hash: Hash::new(0xafab4a2797436aee),
};
pub static GENERATOR_TYPE: &StaticType = &StaticType {
name: "Generator",
hash: Hash::new(0x50deff8c6ef7532c),
};
pub static GENERATOR_STATE_TYPE: &StaticType = &StaticType {
name: "GeneratorState",
hash: Hash::new(0xdd4141d4d8a3ac31),
};
pub static STREAM_TYPE: &StaticType = &StaticType {
name: "Stream",
hash: Hash::new(0xd94133730d02c3ea),
};
pub static RESULT_TYPE: &StaticType = &StaticType {
name: "Result",
hash: Hash::new(0xecec15e1363240ac),
};
pub static OPTION_TYPE: &StaticType = &StaticType {
name: "Option",
hash: Hash::new(0x5e08dc3f663c72db),
};
pub static FUNCTION_TYPE: &StaticType = &StaticType {
name: "Function",
hash: Hash::new(0x45b788b02e7f231c),
};