Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 7ff70d4

Browse files
committedMar 23, 2025
Replace elided_named_lifetimes with mismatched_lifetime_syntaxes
1 parent 2b33b87 commit 7ff70d4

File tree

59 files changed

+357
-544
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+357
-544
lines changed
 

‎tests/ui/async-await/issues/issue-63388-1.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ trait Foo {}
99
impl Xyz {
1010
async fn do_sth<'a>(
1111
&'a self, foo: &dyn Foo
12-
) -> &dyn Foo //~ WARNING elided lifetime has a name
12+
) -> &dyn Foo
1313
{
1414
foo
1515
//~^ ERROR explicit lifetime required in the type of `foo` [E0621]
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,3 @@
1-
warning: elided lifetime has a name
2-
--> $DIR/issue-63388-1.rs:12:10
3-
|
4-
LL | async fn do_sth<'a>(
5-
| -- lifetime `'a` declared here
6-
LL | &'a self, foo: &dyn Foo
7-
LL | ) -> &dyn Foo
8-
| ^ this elided lifetime gets resolved as `'a`
9-
|
10-
= note: `#[warn(elided_named_lifetimes)]` on by default
11-
121
error[E0621]: explicit lifetime required in the type of `foo`
132
--> $DIR/issue-63388-1.rs:14:9
143
|
@@ -18,6 +7,6 @@ LL | &'a self, foo: &dyn Foo
187
LL | foo
198
| ^^^ lifetime `'a` required
209

21-
error: aborting due to 1 previous error; 1 warning emitted
10+
error: aborting due to 1 previous error
2211

2312
For more information about this error, try `rustc --explain E0621`.
There was a problem loading the remainder of the diff.

0 commit comments

Comments
 (0)
Failed to load comments.