Skip to content

Commit e2deef3

Browse files
committed
pacify the mercilous tidy.
1 parent ffe87f6 commit e2deef3

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
error[E0309]: the associated type `<T as MyTrait<'_>>::Output` may not live long enough
2+
--> $DIR/projection-where-clause-env-wrong-lifetime.rs:14:5
3+
|
4+
LL | bar::<<T as MyTrait<'a>>::Output>()
5+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
6+
|
7+
= help: consider adding an explicit lifetime bound `<T as MyTrait<'_>>::Output: 'a`...
8+
9+
error: aborting due to previous error
10+
11+
For more information about this error, try `rustc --explain E0309`.

src/test/ui/nll/ty-outlives/projection-where-clause-env-wrong-lifetime.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ where
1111
for<'x> T: MyTrait<'x>,
1212
<T as MyTrait<'b>>::Output: 'a,
1313
{
14-
bar::<<T as MyTrait<'a>>::Output>() //~ ERROR the associated type `<T as MyTrait<'a>>::Output` may not live long enough
14+
bar::<<T as MyTrait<'a>>::Output>()
15+
//~^ ERROR the associated type `<T as MyTrait<'a>>::Output` may not live long enough
1516
}
1617

1718
fn bar<'a, T>() -> &'a ()

src/test/ui/nll/ty-outlives/projection-where-clause-env-wrong-lifetime.stderr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
error[E0309]: the associated type `<T as MyTrait<'a>>::Output` may not live long enough
22
--> $DIR/projection-where-clause-env-wrong-lifetime.rs:14:5
33
|
4-
LL | bar::<<T as MyTrait<'a>>::Output>() //~ ERROR the associated type `<T as MyTrait<'a>>::Output` may not live long enough
4+
LL | bar::<<T as MyTrait<'a>>::Output>()
55
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
66
|
77
= help: consider adding an explicit lifetime bound `<T as MyTrait<'a>>::Output: 'a`...
88
note: ...so that the type `<T as MyTrait<'a>>::Output` will meet its required lifetime bounds
99
--> $DIR/projection-where-clause-env-wrong-lifetime.rs:14:5
1010
|
11-
LL | bar::<<T as MyTrait<'a>>::Output>() //~ ERROR the associated type `<T as MyTrait<'a>>::Output` may not live long enough
11+
LL | bar::<<T as MyTrait<'a>>::Output>()
1212
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1313

1414
error: aborting due to previous error

0 commit comments

Comments
 (0)