1
0
mirror of https://github.com/emilk/egui.git synced 2026-09-02 06:40:06 -04:00

Use Rust edition 2024 (#7280)

This commit is contained in:
Emil Ernerfeldt
2025-06-30 14:01:57 +02:00
committed by GitHub
parent 962c8e26a8
commit b2995dcb83
190 changed files with 427 additions and 388 deletions

View File

@@ -128,11 +128,17 @@ impl Display for SnapshotError {
write!(f, "Missing snapshot: {path:?}. {HOW_TO_UPDATE_SCREENSHOTS}")
}
err => {
write!(f, "Error reading snapshot: {err:?}\nAt: {path:?}. {HOW_TO_UPDATE_SCREENSHOTS}")
write!(
f,
"Error reading snapshot: {err:?}\nAt: {path:?}. {HOW_TO_UPDATE_SCREENSHOTS}"
)
}
},
err => {
write!(f, "Error decoding snapshot: {err:?}\nAt: {path:?}. Make sure git-lfs is setup correctly. Read the instructions here: https://github.com/emilk/egui/blob/main/CONTRIBUTING.md#making-a-pr")
write!(
f,
"Error decoding snapshot: {err:?}\nAt: {path:?}. Make sure git-lfs is setup correctly. Read the instructions here: https://github.com/emilk/egui/blob/main/CONTRIBUTING.md#making-a-pr"
)
}
}
}
@@ -555,11 +561,7 @@ impl SnapshotResults {
/// Convert this into a `Result<(), Self>`.
#[expect(clippy::missing_errors_doc)]
pub fn into_result(self) -> Result<(), Self> {
if self.has_errors() {
Err(self)
} else {
Ok(())
}
if self.has_errors() { Err(self) } else { Ok(()) }
}
pub fn into_inner(mut self) -> Vec<SnapshotError> {