blob: a4eebab38639e884f342a1759dbfc0c33cff8049 [file] [log] [blame]
error[E0308]: mismatched types
--> $DIR/regions-bounds.rs:9:12
|
LL | return e;
| ^ lifetime mismatch
|
= note: expected struct `TupleStruct<'b>`
found struct `TupleStruct<'a>`
note: the lifetime `'a` as defined on the function body at 8:10...
--> $DIR/regions-bounds.rs:8:10
|
LL | fn a_fn1<'a,'b>(e: TupleStruct<'a>) -> TupleStruct<'b> {
| ^^
note: ...does not necessarily outlive the lifetime `'b` as defined on the function body at 8:13
--> $DIR/regions-bounds.rs:8:13
|
LL | fn a_fn1<'a,'b>(e: TupleStruct<'a>) -> TupleStruct<'b> {
| ^^
error[E0308]: mismatched types
--> $DIR/regions-bounds.rs:13:12
|
LL | return e;
| ^ lifetime mismatch
|
= note: expected struct `Struct<'b>`
found struct `Struct<'a>`
note: the lifetime `'a` as defined on the function body at 12:10...
--> $DIR/regions-bounds.rs:12:10
|
LL | fn a_fn3<'a,'b>(e: Struct<'a>) -> Struct<'b> {
| ^^
note: ...does not necessarily outlive the lifetime `'b` as defined on the function body at 12:13
--> $DIR/regions-bounds.rs:12:13
|
LL | fn a_fn3<'a,'b>(e: Struct<'a>) -> Struct<'b> {
| ^^
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0308`.