-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Open
Labels
C-bugCategory: This is a bug.Category: This is a bug.L-mismatched_lifetime_syntaxesLint: mismatched_lifetime_syntaxesLint: mismatched_lifetime_syntaxesneeds-triageThis issue may need triage. Remove it if it has been sufficiently triaged.This issue may need triage. Remove it if it has been sufficiently triaged.
Description
Rust is about to start warning about this by default, which can trigger a lot of warnings, but unfortunately the warnings can't be fixed automatically:
#![warn(mismatched_lifetime_syntaxes)]
fn lifetimes(x: &str) -> std::borrow::Cow<str> {
x.into()
}
Running these commands has no effect:
cargo fix
cargo fix --broken-code
cargo clippy --fix
cargo clippy --fix --broken-code
The code remains unfixed, and the warning keeps triggering.
cargo 1.90.0-nightly (9b296973b 2025-07-25)
rustc 1.90.0-nightly (f8e355c 2025-07-27)
Metadata
Metadata
Assignees
Labels
C-bugCategory: This is a bug.Category: This is a bug.L-mismatched_lifetime_syntaxesLint: mismatched_lifetime_syntaxesLint: mismatched_lifetime_syntaxesneeds-triageThis issue may need triage. Remove it if it has been sufficiently triaged.This issue may need triage. Remove it if it has been sufficiently triaged.