error: lifetime may not live long enough --> $DIR/regions-trait-object-subtyping.rs:15:5 | LL | fn foo3<'a,'b>(x: &'a mut dyn Dummy) -> &'b mut dyn Dummy { | -- -- lifetime `'b` defined here | | | lifetime `'a` defined here LL | // Without knowing 'a:'b, we can't coerce LL | x | ^ returning this value requires that `'a` must outlive `'b` error: lifetime may not live long enough --> $DIR/regions-trait-object-subtyping.rs:22:5 | LL | fn foo4<'a:'b,'b>(x: Wrapper<&'a mut dyn Dummy>) -> Wrapper<&'b mut dyn Dummy> { | -- -- lifetime `'b` defined here | | | lifetime `'a` defined here LL | // We can't coerce because it is packed in `Wrapper` LL | x | ^ returning this value requires that `'b` must outlive `'a` error: aborting due to 2 previous errors