aboutsummaryrefslogtreecommitdiffstats
path: root/crates/bytes/src/error.rs
diff options
context:
space:
mode:
authorBenedikt Peetz <benedikt.peetz@b-peetz.de>2024-10-14 18:05:33 +0200
committerBenedikt Peetz <benedikt.peetz@b-peetz.de>2024-10-14 18:05:33 +0200
commit2c7980b773cad586af5db8ff0755f1d74d94f7d1 (patch)
tree5207aa3a69945ae7d5e5ef77ad14a50313954c25 /crates/bytes/src/error.rs
parentfeat(unreachable): Init trait (diff)
downloadyt-2c7980b773cad586af5db8ff0755f1d74d94f7d1.zip
refactor(treewide): Conform to the clippy and rust lints
Diffstat (limited to 'crates/bytes/src/error.rs')
-rw-r--r--crates/bytes/src/error.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/crates/bytes/src/error.rs b/crates/bytes/src/error.rs
index 7643109..c9783d8 100644
--- a/crates/bytes/src/error.rs
+++ b/crates/bytes/src/error.rs
@@ -11,6 +11,7 @@
use std::{fmt::Display, num::ParseIntError};
#[derive(Debug)]
+#[allow(clippy::module_name_repetitions)]
pub enum BytesError {
BytesParseIntError(ParseIntError),
NotYetSupported(String),
@@ -20,10 +21,10 @@ impl Display for BytesError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
BytesError::BytesParseIntError(e) => {
- f.write_fmt(format_args!("Failed to parse a number as integer: '{}'", e))
+ f.write_fmt(format_args!("Failed to parse a number as integer: '{e}'"))
},
BytesError::NotYetSupported(other) => {
- f.write_fmt(format_args!("Your extension '{}' is not yet supported. Only KB,MB,GB or KiB,MiB,GiB are supported", other))
+ f.write_fmt(format_args!("Your extension '{other}' is not yet supported. Only KB,MB,GB or KiB,MiB,GiB are supported"))
}
}
}