lint: only consider actual calls as unconditional recursion.
Specifically, just mentioning the function name as a value is fine, as
long as it isn't called, e.g. `fn main() { let _ = main; }`.
Closes #21705.
This commit is contained in:
@@ -63,4 +63,8 @@ impl Baz {
|
||||
}
|
||||
}
|
||||
|
||||
fn all_fine() {
|
||||
let _f = all_fine;
|
||||
}
|
||||
|
||||
fn main() {}
|
||||
|
||||
Reference in New Issue
Block a user