Closed pheiduck closed 1 year ago
calling it an "error" is FUD, it's a stylistic choice, and it necessarily drastically cuts off MSRV (in this case: past bullseye cargo/rustc)
calling it an "error" is FUD, it's a stylistic choice, and it necessarily drastically cuts off MSRV (in this case: past bullseye cargo/rustc)
Agree, it introduce build regressions as well so, we will see how this endup in future releases of rust.
I would leave this open to work on.
@nabijaczleweli @keszybz you can review it again.
Fixes are no longer necessary I will close this PR. https://github.com/systemd/zram-generator/commit/af6fffe43a24b335abef3fd0f9b0bffdee4ef4c0 fixes some of them or of newer Rust Versions
Added in: 1.65.0
uninlined_format_args
What it does? Detect when a variable is not inlined in a format string, and suggests to inline it. Why is this bad? Non-inlined code is slightly more difficult to read and understand, as it requires arguments to be matched against the format string. The inlined syntax, where allowed, is simpler.Examples:
Use instead:
If allow-mixed-uninlined-format-args is set to false in clippy.toml, the following code will also trigger the lint:
format!("{} {}", var, 1+2);
Use instead:format!("{var} {}", 1+2);