11 lines
140 B
Rust
11 lines
140 B
Rust
|
fn f<T>(x: T) -> @T {
|
||
|
@x //~ ERROR value may contain borrowed pointers
|
||
|
}
|
||
|
|
||
|
fn g<T:'static>(x: T) -> @T {
|
||
|
@x // ok
|
||
|
}
|
||
|
|
||
|
fn main() {}
|
||
|
|