2021-12-31 21:55:34 +00:00
|
|
|
error: lifetime may not live long enough
|
2022-04-01 17:13:25 +00:00
|
|
|
--> $DIR/issue-16683.rs:4:9
|
2019-01-27 11:03:21 +00:00
|
|
|
|
|
2021-10-03 20:25:26 +00:00
|
|
|
LL | trait T<'a> {
|
|
|
|
| -- lifetime `'a` defined here
|
|
|
|
LL | fn a(&'a self) -> &'a bool;
|
2019-01-27 11:03:21 +00:00
|
|
|
LL | fn b(&self) {
|
2021-12-31 21:55:34 +00:00
|
|
|
| - let's call the lifetime of this reference `'1`
|
2019-01-27 11:03:21 +00:00
|
|
|
LL | self.a();
|
2021-12-31 21:55:34 +00:00
|
|
|
| ^^^^^^^^ argument requires that `'1` must outlive `'a`
|
2019-01-27 11:03:21 +00:00
|
|
|
|
2023-11-21 15:44:16 +00:00
|
|
|
error: aborting due to 1 previous error
|
2019-01-27 11:03:21 +00:00
|
|
|
|