Skip to content

Commit a8bb0c1

Browse files
lcnrmark-i-m
authored andcommitted
Fix example for winnowing
1 parent 98e94be commit a8bb0c1

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

src/traits/resolution.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -191,12 +191,16 @@ trait Get {
191191
fn get(&self) -> Self;
192192
}
193193
194-
impl<T:Copy> Get for T {
195-
fn get(&self) -> T { *self }
194+
impl<T: Copy> Get for T {
195+
fn get(&self) -> T {
196+
*self
197+
}
196198
}
197199
198-
impl<T:Get> Get for Box<T> {
199-
fn get(&self) -> Box<T> { Box::new(get_it(&**self)) }
200+
impl<T: Get> Get for Box<T> {
201+
fn get(&self) -> Box<T> {
202+
Box::new(<T>::get(self))
203+
}
200204
}
201205
```
202206

0 commit comments

Comments
 (0)