60ae1590af
And remove support for the old syntax
10 lines
207 B
Rust
10 lines
207 B
Rust
type recbox<T: copy> = {x: ~T};
|
|
|
|
fn reclift<T: copy>(t: T) -> recbox<T> { ret {x: ~t}; }
|
|
|
|
fn main() {
|
|
let foo: int = 17;
|
|
let rbfoo: recbox<int> = reclift::<int>(foo);
|
|
assert (*rbfoo.x == foo);
|
|
}
|