]> git.proxmox.com Git - rustc.git/blame - src/test/ui/regions/region-object-lifetime-4.base.stderr
New upstream version 1.62.1+dfsg1
[rustc.git] / src / test / ui / regions / region-object-lifetime-4.base.stderr
CommitLineData
b7449926 1error[E0495]: cannot infer an appropriate lifetime for autoref due to conflicting requirements
04454e1e 2 --> $DIR/region-object-lifetime-4.rs:16:7
b7449926 3 |
532ac7d7 4LL | x.borrowed()
b7449926
XL
5 | ^^^^^^^^
6 |
c295e0f8 7note: first, the lifetime cannot outlive the lifetime `'a` as defined here...
04454e1e 8 --> $DIR/region-object-lifetime-4.rs:15:41
b7449926 9 |
dc9dc135 10LL | fn borrowed_receiver_related_lifetimes2<'a,'b>(x: &'a (dyn Foo + 'b)) -> &'b () {
b7449926
XL
11 | ^^
12note: ...so that reference does not outlive borrowed content
04454e1e 13 --> $DIR/region-object-lifetime-4.rs:16:5
b7449926 14 |
532ac7d7 15LL | x.borrowed()
b7449926 16 | ^
c295e0f8 17note: but, the lifetime must be valid for the lifetime `'b` as defined here...
04454e1e 18 --> $DIR/region-object-lifetime-4.rs:15:44
b7449926 19 |
dc9dc135 20LL | fn borrowed_receiver_related_lifetimes2<'a,'b>(x: &'a (dyn Foo + 'b)) -> &'b () {
b7449926
XL
21 | ^^
22note: ...so that reference does not outlive borrowed content
04454e1e 23 --> $DIR/region-object-lifetime-4.rs:16:5
b7449926 24 |
532ac7d7 25LL | x.borrowed()
b7449926
XL
26 | ^^^^^^^^^^^^
27
28error: aborting due to previous error
29
e74abb32 30For more information about this error, try `rustc --explain E0495`.