mirror of
https://github.com/rust-lang/rust.git
synced 2024-10-31 22:41:50 +00:00
12 lines
152 B
Rust
12 lines
152 B
Rust
// run-pass
|
|
|
|
fn f<T>(t: T) -> T {
|
|
let t1 = t;
|
|
t1
|
|
}
|
|
|
|
pub fn main() {
|
|
let t = f::<Box<_>>(Box::new(100));
|
|
assert_eq!(t, Box::new(100));
|
|
}
|