We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Clippy and rustc don't seem to agree when it comes to declaring static associated constant lifetimes.
trait Foo { const BAR: &'static str = "bar"; }
clippy
warning: Constants have by default a `'static` lifetime --> src/main.rs:5:17 | 5 | const BAR: &'static str = "bar"; | -^^^^^^^---- help: consider removing `'static`: `&str`
rustc
error[E0106]: missing lifetime specifier --> src/main.rs:5:16 | 5 | const BAR: &str = "bar"; | ^ expected lifetime parameter
The text was updated successfully, but these errors were encountered:
This should have been fixed in #2443. Have you tried to update clippy recently?
Sorry, something went wrong.
Thanks, this indeed does not occur on current master
No branches or pull requests
Clippy and rustc don't seem to agree when it comes to declaring static associated constant lifetimes.
clippy
rustc
The text was updated successfully, but these errors were encountered: