diff options
Diffstat (limited to 'src/test/compile-fail/owned-ptr-static-bound.rs')
| -rw-r--r-- | src/test/compile-fail/owned-ptr-static-bound.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/test/compile-fail/owned-ptr-static-bound.rs b/src/test/compile-fail/owned-ptr-static-bound.rs index 48f04c33494..dc6e8b1d6be 100644 --- a/src/test/compile-fail/owned-ptr-static-bound.rs +++ b/src/test/compile-fail/owned-ptr-static-bound.rs @@ -15,16 +15,16 @@ struct B<'a, T>(&'a A<T>); trait X {} impl<'a, T> X for B<'a, T> {} -fn f<'a, T, U>(v: Box<A<T>>) -> Box<X:> { - box B(v) as Box<X:> //~ ERROR value may contain references; add `'static` bound to `T` +fn f<'a, T, U>(v: Box<A<T>>) -> Box<X> { + box B(v) as Box<X> //~ ERROR value may contain references; add `'static` bound to `T` } -fn g<'a, T, U>(v: Box<A<U>>) -> Box<X:> { - box B(v) as Box<X:> //~ ERROR value may contain references; add `'static` bound to `U` +fn g<'a, T, U>(v: Box<A<U>>) -> Box<X> { + box B(v) as Box<X> //~ ERROR value may contain references; add `'static` bound to `U` } -fn h<'a, T: 'static>(v: Box<A<T>>) -> Box<X:> { - box B(v) as Box<X:> // ok +fn h<'a, T: 'static>(v: Box<A<T>>) -> Box<X> { + box B(v) as Box<X> // ok } fn main() {} |
