From 2e2121fd2e7037dbb27a0e9a43c6c1a24ab9cce6 Mon Sep 17 00:00:00 2001 From: lazymio Date: Fri, 25 Oct 2024 20:45:41 +0800 Subject: [PATCH] Implement DerefMut for Log --- crates/primitives/src/log/mod.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/crates/primitives/src/log/mod.rs b/crates/primitives/src/log/mod.rs index 712e1ca91..4d6612b11 100644 --- a/crates/primitives/src/log/mod.rs +++ b/crates/primitives/src/log/mod.rs @@ -132,6 +132,13 @@ impl core::ops::Deref for Log { } } +impl core::ops::DerefMut for Log { + #[inline] + fn deref_mut(&mut self) -> &mut Self::Target { + &mut self.data + } +} + impl Log { /// Creates a new log. #[inline]