Fix example for winnowing
This commit is contained in:
parent
5ddf4f6ad1
commit
3f7d16743c
1 changed files with 8 additions and 4 deletions
|
|
@ -191,12 +191,16 @@ trait Get {
|
|||
fn get(&self) -> Self;
|
||||
}
|
||||
|
||||
impl<T:Copy> Get for T {
|
||||
fn get(&self) -> T { *self }
|
||||
impl<T: Copy> Get for T {
|
||||
fn get(&self) -> T {
|
||||
*self
|
||||
}
|
||||
}
|
||||
|
||||
impl<T:Get> Get for Box<T> {
|
||||
fn get(&self) -> Box<T> { Box::new(get_it(&**self)) }
|
||||
impl<T: Get> Get for Box<T> {
|
||||
fn get(&self) -> Box<T> {
|
||||
Box::new(<T>::get(self))
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue