blob: ef62afbef3bd6c16260b9a3c27fc8993e695c67b [file] [log] [blame]
error[E0495]: cannot infer an appropriate lifetime for autoref due to conflicting requirements
--> $DIR/region-object-lifetime-4.rs:22:7
|
LL | x.borrowed() //~ ERROR cannot infer
| ^^^^^^^^
|
note: first, the lifetime cannot outlive the lifetime 'a as defined on the function body at 21:41...
--> $DIR/region-object-lifetime-4.rs:21:41
|
LL | fn borrowed_receiver_related_lifetimes2<'a,'b>(x: &'a (Foo+'b)) -> &'b () {
| ^^
note: ...so that reference does not outlive borrowed content
--> $DIR/region-object-lifetime-4.rs:22:5
|
LL | x.borrowed() //~ ERROR cannot infer
| ^
note: but, the lifetime must be valid for the lifetime 'b as defined on the function body at 21:44...
--> $DIR/region-object-lifetime-4.rs:21:44
|
LL | fn borrowed_receiver_related_lifetimes2<'a,'b>(x: &'a (Foo+'b)) -> &'b () {
| ^^
note: ...so that reference does not outlive borrowed content
--> $DIR/region-object-lifetime-4.rs:22:5
|
LL | x.borrowed() //~ ERROR cannot infer
| ^^^^^^^^^^^^
error: aborting due to previous error
For more information about this error, try `rustc --explain E0495`.