]> git.lizzy.rs Git - rust.git/blob - src/test/ui/coercion/issue-53475.rs
Rollup merge of #99928 - compiler-errors:issue-99914, r=oli-obk
[rust.git] / src / test / ui / coercion / issue-53475.rs
1 #![feature(coerce_unsized)]
2
3 use std::any::Any;
4 use std::ops::CoerceUnsized;
5
6 struct Foo<T> {
7     data: Box<T>,
8 }
9
10 impl<T> CoerceUnsized<Foo<dyn Any>> for Foo<T> {}
11 //~^ ERROR the parameter type `T` may not live long enough
12
13 fn main() {}