tet_core/
u32_trait.rs

1// This file is part of Tetcore.
2
3// Copyright (C) 2017-2021 Parity Technologies (UK) Ltd.
4// SPDX-License-Identifier: Apache-2.0
5
6// Licensed under the Apache License, Version 2.0 (the "License");
7// you may not use this file except in compliance with the License.
8// You may obtain a copy of the License at
9//
10// 	http://www.apache.org/licenses/LICENSE-2.0
11//
12// Unless required by applicable law or agreed to in writing, software
13// distributed under the License is distributed on an "AS IS" BASIS,
14// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15// See the License for the specific language governing permissions and
16// limitations under the License.
17
18//! An u32 trait with "values" as impl'd types.
19
20/// A u32 value, wrapped in a trait because we don't yet have const generics.
21pub trait Value {
22	/// The actual value represented by the impl'ing type.
23	const VALUE: u32;
24}
25
26/// Type representing the value 0 for the `Value` trait.
27pub struct _0; impl Value for _0 { const VALUE: u32 = 0; }
28/// Type representing the value 1 for the `Value` trait.
29pub struct _1; impl Value for _1 { const VALUE: u32 = 1; }
30/// Type representing the value 2 for the `Value` trait.
31pub struct _2; impl Value for _2 { const VALUE: u32 = 2; }
32/// Type representing the value 3 for the `Value` trait.
33pub struct _3; impl Value for _3 { const VALUE: u32 = 3; }
34/// Type representing the value 4 for the `Value` trait.
35pub struct _4; impl Value for _4 { const VALUE: u32 = 4; }
36/// Type representing the value 5 for the `Value` trait.
37pub struct _5; impl Value for _5 { const VALUE: u32 = 5; }
38/// Type representing the value 6 for the `Value` trait.
39pub struct _6; impl Value for _6 { const VALUE: u32 = 6; }
40/// Type representing the value 7 for the `Value` trait.
41pub struct _7; impl Value for _7 { const VALUE: u32 = 7; }
42/// Type representing the value 8 for the `Value` trait.
43pub struct _8; impl Value for _8 { const VALUE: u32 = 8; }
44/// Type representing the value 9 for the `Value` trait.
45pub struct _9; impl Value for _9 { const VALUE: u32 = 9; }
46/// Type representing the value 10 for the `Value` trait.
47pub struct _10; impl Value for _10 { const VALUE: u32 = 10; }
48/// Type representing the value 11 for the `Value` trait.
49pub struct _11; impl Value for _11 { const VALUE: u32 = 11; }
50/// Type representing the value 12 for the `Value` trait.
51pub struct _12; impl Value for _12 { const VALUE: u32 = 12; }
52/// Type representing the value 13 for the `Value` trait.
53pub struct _13; impl Value for _13 { const VALUE: u32 = 13; }
54/// Type representing the value 14 for the `Value` trait.
55pub struct _14; impl Value for _14 { const VALUE: u32 = 14; }
56/// Type representing the value 15 for the `Value` trait.
57pub struct _15; impl Value for _15 { const VALUE: u32 = 15; }
58/// Type representing the value 16 for the `Value` trait.
59pub struct _16; impl Value for _16 { const VALUE: u32 = 16; }
60/// Type representing the value 17 for the `Value` trait.
61pub struct _17; impl Value for _17 { const VALUE: u32 = 17; }
62/// Type representing the value 18 for the `Value` trait.
63pub struct _18; impl Value for _18 { const VALUE: u32 = 18; }
64/// Type representing the value 19 for the `Value` trait.
65pub struct _19; impl Value for _19 { const VALUE: u32 = 19; }
66/// Type representing the value 20 for the `Value` trait.
67pub struct _20; impl Value for _20 { const VALUE: u32 = 20; }
68/// Type representing the value 21 for the `Value` trait.
69pub struct _21; impl Value for _21 { const VALUE: u32 = 21; }
70/// Type representing the value 22 for the `Value` trait.
71pub struct _22; impl Value for _22 { const VALUE: u32 = 22; }
72/// Type representing the value 23 for the `Value` trait.
73pub struct _23; impl Value for _23 { const VALUE: u32 = 23; }
74/// Type representing the value 24 for the `Value` trait.
75pub struct _24; impl Value for _24 { const VALUE: u32 = 24; }
76/// Type representing the value 25 for the `Value` trait.
77pub struct _25; impl Value for _25 { const VALUE: u32 = 25; }
78/// Type representing the value 26 for the `Value` trait.
79pub struct _26; impl Value for _26 { const VALUE: u32 = 26; }
80/// Type representing the value 27 for the `Value` trait.
81pub struct _27; impl Value for _27 { const VALUE: u32 = 27; }
82/// Type representing the value 28 for the `Value` trait.
83pub struct _28; impl Value for _28 { const VALUE: u32 = 28; }
84/// Type representing the value 29 for the `Value` trait.
85pub struct _29; impl Value for _29 { const VALUE: u32 = 29; }
86/// Type representing the value 30 for the `Value` trait.
87pub struct _30; impl Value for _30 { const VALUE: u32 = 30; }
88/// Type representing the value 31 for the `Value` trait.
89pub struct _31; impl Value for _31 { const VALUE: u32 = 31; }
90/// Type representing the value 32 for the `Value` trait.
91pub struct _32; impl Value for _32 { const VALUE: u32 = 32; }
92/// Type representing the value 33 for the `Value` trait.
93pub struct _33; impl Value for _33 { const VALUE: u32 = 33; }
94/// Type representing the value 34 for the `Value` trait.
95pub struct _34; impl Value for _34 { const VALUE: u32 = 34; }
96/// Type representing the value 35 for the `Value` trait.
97pub struct _35; impl Value for _35 { const VALUE: u32 = 35; }
98/// Type representing the value 36 for the `Value` trait.
99pub struct _36; impl Value for _36 { const VALUE: u32 = 36; }
100/// Type representing the value 37 for the `Value` trait.
101pub struct _37; impl Value for _37 { const VALUE: u32 = 37; }
102/// Type representing the value 38 for the `Value` trait.
103pub struct _38; impl Value for _38 { const VALUE: u32 = 38; }
104/// Type representing the value 39 for the `Value` trait.
105pub struct _39; impl Value for _39 { const VALUE: u32 = 39; }
106/// Type representing the value 40 for the `Value` trait.
107pub struct _40; impl Value for _40 { const VALUE: u32 = 40; }
108/// Type representing the value 41 for the `Value` trait.
109pub struct _41; impl Value for _41 { const VALUE: u32 = 41; }
110/// Type representing the value 42 for the `Value` trait.
111pub struct _42; impl Value for _42 { const VALUE: u32 = 42; }
112/// Type representing the value 43 for the `Value` trait.
113pub struct _43; impl Value for _43 { const VALUE: u32 = 43; }
114/// Type representing the value 44 for the `Value` trait.
115pub struct _44; impl Value for _44 { const VALUE: u32 = 44; }
116/// Type representing the value 45 for the `Value` trait.
117pub struct _45; impl Value for _45 { const VALUE: u32 = 45; }
118/// Type representing the value 46 for the `Value` trait.
119pub struct _46; impl Value for _46 { const VALUE: u32 = 46; }
120/// Type representing the value 47 for the `Value` trait.
121pub struct _47; impl Value for _47 { const VALUE: u32 = 47; }
122/// Type representing the value 48 for the `Value` trait.
123pub struct _48; impl Value for _48 { const VALUE: u32 = 48; }
124/// Type representing the value 49 for the `Value` trait.
125pub struct _49; impl Value for _49 { const VALUE: u32 = 49; }
126/// Type representing the value 50 for the `Value` trait.
127pub struct _50; impl Value for _50 { const VALUE: u32 = 50; }
128/// Type representing the value 51 for the `Value` trait.
129pub struct _51; impl Value for _51 { const VALUE: u32 = 51; }
130/// Type representing the value 52 for the `Value` trait.
131pub struct _52; impl Value for _52 { const VALUE: u32 = 52; }
132/// Type representing the value 53 for the `Value` trait.
133pub struct _53; impl Value for _53 { const VALUE: u32 = 53; }
134/// Type representing the value 54 for the `Value` trait.
135pub struct _54; impl Value for _54 { const VALUE: u32 = 54; }
136/// Type representing the value 55 for the `Value` trait.
137pub struct _55; impl Value for _55 { const VALUE: u32 = 55; }
138/// Type representing the value 56 for the `Value` trait.
139pub struct _56; impl Value for _56 { const VALUE: u32 = 56; }
140/// Type representing the value 57 for the `Value` trait.
141pub struct _57; impl Value for _57 { const VALUE: u32 = 57; }
142/// Type representing the value 58 for the `Value` trait.
143pub struct _58; impl Value for _58 { const VALUE: u32 = 58; }
144/// Type representing the value 59 for the `Value` trait.
145pub struct _59; impl Value for _59 { const VALUE: u32 = 59; }
146/// Type representing the value 60 for the `Value` trait.
147pub struct _60; impl Value for _60 { const VALUE: u32 = 60; }
148/// Type representing the value 61 for the `Value` trait.
149pub struct _61; impl Value for _61 { const VALUE: u32 = 61; }
150/// Type representing the value 62 for the `Value` trait.
151pub struct _62; impl Value for _62 { const VALUE: u32 = 62; }
152/// Type representing the value 63 for the `Value` trait.
153pub struct _63; impl Value for _63 { const VALUE: u32 = 63; }
154/// Type representing the value 64 for the `Value` trait.
155pub struct _64; impl Value for _64 { const VALUE: u32 = 64; }
156/// Type representing the value 65 for the `Value` trait.
157pub struct _65; impl Value for _65 { const VALUE: u32 = 65; }
158/// Type representing the value 66 for the `Value` trait.
159pub struct _66; impl Value for _66 { const VALUE: u32 = 66; }
160/// Type representing the value 67 for the `Value` trait.
161pub struct _67; impl Value for _67 { const VALUE: u32 = 67; }
162/// Type representing the value 68 for the `Value` trait.
163pub struct _68; impl Value for _68 { const VALUE: u32 = 68; }
164/// Type representing the value 69 for the `Value` trait.
165pub struct _69; impl Value for _69 { const VALUE: u32 = 69; }
166/// Type representing the value 70 for the `Value` trait.
167pub struct _70; impl Value for _70 { const VALUE: u32 = 70; }
168/// Type representing the value 71 for the `Value` trait.
169pub struct _71; impl Value for _71 { const VALUE: u32 = 71; }
170/// Type representing the value 72 for the `Value` trait.
171pub struct _72; impl Value for _72 { const VALUE: u32 = 72; }
172/// Type representing the value 73 for the `Value` trait.
173pub struct _73; impl Value for _73 { const VALUE: u32 = 73; }
174/// Type representing the value 74 for the `Value` trait.
175pub struct _74; impl Value for _74 { const VALUE: u32 = 74; }
176/// Type representing the value 75 for the `Value` trait.
177pub struct _75; impl Value for _75 { const VALUE: u32 = 75; }
178/// Type representing the value 76 for the `Value` trait.
179pub struct _76; impl Value for _76 { const VALUE: u32 = 76; }
180/// Type representing the value 77 for the `Value` trait.
181pub struct _77; impl Value for _77 { const VALUE: u32 = 77; }
182/// Type representing the value 78 for the `Value` trait.
183pub struct _78; impl Value for _78 { const VALUE: u32 = 78; }
184/// Type representing the value 79 for the `Value` trait.
185pub struct _79; impl Value for _79 { const VALUE: u32 = 79; }
186/// Type representing the value 80 for the `Value` trait.
187pub struct _80; impl Value for _80 { const VALUE: u32 = 80; }
188/// Type representing the value 81 for the `Value` trait.
189pub struct _81; impl Value for _81 { const VALUE: u32 = 81; }
190/// Type representing the value 82 for the `Value` trait.
191pub struct _82; impl Value for _82 { const VALUE: u32 = 82; }
192/// Type representing the value 83 for the `Value` trait.
193pub struct _83; impl Value for _83 { const VALUE: u32 = 83; }
194/// Type representing the value 84 for the `Value` trait.
195pub struct _84; impl Value for _84 { const VALUE: u32 = 84; }
196/// Type representing the value 85 for the `Value` trait.
197pub struct _85; impl Value for _85 { const VALUE: u32 = 85; }
198/// Type representing the value 86 for the `Value` trait.
199pub struct _86; impl Value for _86 { const VALUE: u32 = 86; }
200/// Type representing the value 87 for the `Value` trait.
201pub struct _87; impl Value for _87 { const VALUE: u32 = 87; }
202/// Type representing the value 88 for the `Value` trait.
203pub struct _88; impl Value for _88 { const VALUE: u32 = 88; }
204/// Type representing the value 89 for the `Value` trait.
205pub struct _89; impl Value for _89 { const VALUE: u32 = 89; }
206/// Type representing the value 90 for the `Value` trait.
207pub struct _90; impl Value for _90 { const VALUE: u32 = 90; }
208/// Type representing the value 91 for the `Value` trait.
209pub struct _91; impl Value for _91 { const VALUE: u32 = 91; }
210/// Type representing the value 92 for the `Value` trait.
211pub struct _92; impl Value for _92 { const VALUE: u32 = 92; }
212/// Type representing the value 93 for the `Value` trait.
213pub struct _93; impl Value for _93 { const VALUE: u32 = 93; }
214/// Type representing the value 94 for the `Value` trait.
215pub struct _94; impl Value for _94 { const VALUE: u32 = 94; }
216/// Type representing the value 95 for the `Value` trait.
217pub struct _95; impl Value for _95 { const VALUE: u32 = 95; }
218/// Type representing the value 96 for the `Value` trait.
219pub struct _96; impl Value for _96 { const VALUE: u32 = 96; }
220/// Type representing the value 97 for the `Value` trait.
221pub struct _97; impl Value for _97 { const VALUE: u32 = 97; }
222/// Type representing the value 98 for the `Value` trait.
223pub struct _98; impl Value for _98 { const VALUE: u32 = 98; }
224/// Type representing the value 99 for the `Value` trait.
225pub struct _99; impl Value for _99 { const VALUE: u32 = 99; }
226/// Type representing the value 100 for the `Value` trait.
227pub struct _100; impl Value for _100 { const VALUE: u32 = 100; }
228/// Type representing the value 112 for the `Value` trait.
229pub struct _112; impl Value for _112 { const VALUE: u32 = 112; }
230/// Type representing the value 128 for the `Value` trait.
231pub struct _128; impl Value for _128 { const VALUE: u32 = 128; }
232/// Type representing the value 160 for the `Value` trait.
233pub struct _160; impl Value for _160 { const VALUE: u32 = 160; }
234/// Type representing the value 192 for the `Value` trait.
235pub struct _192; impl Value for _192 { const VALUE: u32 = 192; }
236/// Type representing the value 224 for the `Value` trait.
237pub struct _224; impl Value for _224 { const VALUE: u32 = 224; }
238/// Type representing the value 256 for the `Value` trait.
239pub struct _256; impl Value for _256 { const VALUE: u32 = 256; }
240/// Type representing the value 384 for the `Value` trait.
241pub struct _384; impl Value for _384 { const VALUE: u32 = 384; }
242/// Type representing the value 512 for the `Value` trait.
243pub struct _512; impl Value for _512 { const VALUE: u32 = 512; }
244