Fix typo in needless_lifetimes test

This commit is contained in:
Samuel Moelius 2024-08-18 13:42:16 -04:00
parent 66f1f544af
commit 5c2f6db289
3 changed files with 7 additions and 7 deletions

View File

@ -384,7 +384,7 @@ mod nested_elision_sites {
f()
}
// lint
fn where_clause_elidadable<T>(i: &i32, f: T) -> &i32
fn where_clause_elidable<T>(i: &i32, f: T) -> &i32
where
T: Fn(&i32) -> &i32,
{

View File

@ -384,7 +384,7 @@ mod nested_elision_sites {
f()
}
// lint
fn where_clause_elidadable<'a, T>(i: &'a i32, f: T) -> &'a i32
fn where_clause_elidable<'a, T>(i: &'a i32, f: T) -> &'a i32
where
T: Fn(&i32) -> &i32,
{

View File

@ -384,15 +384,15 @@ LL + fn generics_elidable<T: Fn(&i32) -> &i32>(i: &i32, f: T) -> &i32 {
|
error: the following explicit lifetimes could be elided: 'a
--> tests/ui/needless_lifetimes.rs:387:32
--> tests/ui/needless_lifetimes.rs:387:30
|
LL | fn where_clause_elidadable<'a, T>(i: &'a i32, f: T) -> &'a i32
| ^^ ^^ ^^
LL | fn where_clause_elidable<'a, T>(i: &'a i32, f: T) -> &'a i32
| ^^ ^^ ^^
|
help: elide the lifetimes
|
LL - fn where_clause_elidadable<'a, T>(i: &'a i32, f: T) -> &'a i32
LL + fn where_clause_elidadable<T>(i: &i32, f: T) -> &i32
LL - fn where_clause_elidable<'a, T>(i: &'a i32, f: T) -> &'a i32
LL + fn where_clause_elidable<T>(i: &i32, f: T) -> &i32
|
error: the following explicit lifetimes could be elided: 'a