diff options
Diffstat (limited to 'crates/core/src/hive')
-rw-r--r-- | crates/core/src/hive/mod.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/core/src/hive/mod.rs b/crates/core/src/hive/mod.rs index ad14725..3f83099 100644 --- a/crates/core/src/hive/mod.rs +++ b/crates/core/src/hive/mod.rs @@ -297,8 +297,8 @@ pub enum Error { #[cfg(feature = "core-fmt")] impl fmt::Display for Error { - fn fmt(&self, fmt: &mut fmt::Formatter<'_>) -> Result<(), fmt::Error> { - fmt.write_str("memory allocation failed")?; + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + f.write_str("memory allocation failed")?; let reason = match self { Error::CapacityOverflow => { " because the computed capacity exceeded the hive's maximum" @@ -307,7 +307,7 @@ impl fmt::Display for Error { " because the memory allocator returned an error" } }; - fmt.write_str(reason) + f.write_str(reason) } } |