File tree 2 files changed +0
-52
lines changed
2 files changed +0
-52
lines changed Original file line number Diff line number Diff line change @@ -29,7 +29,6 @@ impl<H: 'static + Hasher> AnyHasher for H {
29
29
}
30
30
}
31
31
32
- // TODO: but now I want this not for everything
33
32
impl < T : ' static + Hash > MyTrait for T {
34
33
fn as_any ( & self ) -> & Any {
35
34
self as & Any
@@ -41,9 +40,6 @@ impl<T: 'static + Hash> MyTrait for T {
41
40
}
42
41
}
43
42
44
- //impl MyTrait for A {}
45
- //impl MyTrait for B {}
46
-
47
43
impl Hash for MyTrait {
48
44
fn hash < H : Hasher > ( & self , hasher : & mut H ) {
49
45
self . my_hash ( hasher)
@@ -57,48 +53,3 @@ fn main() {
57
53
let x: & MyTrait = & A ( 1 ) ;
58
54
x. hash ( & mut hasher) ;
59
55
}
60
-
61
-
62
- //trait PreS: Debug {}
63
- //
64
- //trait HasherAsAny {
65
- // fn as_any(&self) -> &Any;
66
- //}
67
- //
68
- //trait PostS {
69
- // fn as_any(&self) -> &Any;
70
- //
71
- // fn _hash<H: Hasher>(&self, hasher: H);
72
- //}
73
- //
74
- //impl<T: 'static + Hasher> HasherAsAny for T {
75
- // fn as_any(&self) -> &Any {
76
- // self as &Any
77
- // }
78
- //}
79
- //
80
- //impl<T: 'static + PreS> PostS for T {
81
- // fn as_any(&self) -> &Any {
82
- // self as &Any
83
- // }
84
- //
85
- // fn _hash<H: Hasher>(&self, hasher: H) {
86
- // self.as_any().downcast_ref::<T>().hash(hasher)
87
- // }
88
- //}
89
- //
90
- //impl PreS for A {}
91
- //
92
- //impl PreS for B {}
93
- //
94
- //impl Hash for PostS {
95
- // fn hash(&self, hasher: &mut HasherAsAny) {
96
- // self._hash(hasher.as_any().downcast_ref::<T>())
97
- // }
98
- //}
99
- //
100
- //fn main() {
101
- // let x: &PostS = &A(1);
102
- // let m = HashMap::new();
103
- // m.insert(x, 0);
104
- //}
Original file line number Diff line number Diff line change 1
1
#![ feature( nll) ]
2
2
//#![feature(generators, generator_trait)]
3
-
4
3
#![ feature( proc_macro, wasm_custom_section, wasm_import_module) ]
5
4
extern crate core;
6
5
extern crate wasm_bindgen;
@@ -13,9 +12,7 @@ extern crate derive_new;
13
12
14
13
pub mod mango {
15
14
// Utilities
16
- pub mod cli;
17
15
pub mod io;
18
-
19
16
pub mod jit;
20
17
pub mod ui;
21
18
pub mod util;
You can’t perform that action at this time.
0 commit comments