about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--library/core/src/alloc/mod.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/library/core/src/alloc/mod.rs b/library/core/src/alloc/mod.rs
index f9eb8981bbf..6b14e06e452 100644
--- a/library/core/src/alloc/mod.rs
+++ b/library/core/src/alloc/mod.rs
@@ -337,7 +337,7 @@ pub unsafe trait AllocRef {
     ///
     /// The returned adaptor also implements `AllocRef` and will simply borrow this.
     #[inline(always)]
-    fn by_ref(&mut self) -> &Self {
+    fn by_ref(&self) -> &Self {
         self
     }
 }