mirror of
https://github.com/emilk/egui.git
synced 2026-08-29 04:40:03 -04:00
Enable a few more clippy lints (#8064)
Enable these new clippy lints and fix all warnings: * `format_push_string` — use `write!` instead of `s += &format!(…)` to avoid extra allocations * `ignored_unit_patterns` — use `()` instead of `_` when matching unit * `missing_fields_in_debug` — ensure manual `Debug` impls account for all fields * `needless_raw_string_hashes` — remove unnecessary `r#` on string literals * `ref_option` — prefer `Option<&T>` over `&Option<T>` in function signatures
This commit is contained in:
@@ -207,7 +207,7 @@ fn save_to_disk(file_path: &PathBuf, kv: &HashMap<String, String>) {
|
||||
profiling::scope!("ron::serialize");
|
||||
if let Err(err) = ron::Options::default()
|
||||
.to_io_writer_pretty(&mut writer, &kv, config)
|
||||
.and_then(|_| writer.flush().map_err(|err| err.into()))
|
||||
.and_then(|()| writer.flush().map_err(|err| err.into()))
|
||||
{
|
||||
log::warn!("Failed to serialize app state: {err}");
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user