Skip to content

Commit a87b419

Browse files
committed
Change AllocRef::by_ref to take &self instead of &mut self
1 parent 7b59d01 commit a87b419

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/src/alloc/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ pub unsafe trait AllocRef {
337337
///
338338
/// The returned adaptor also implements `AllocRef` and will simply borrow this.
339339
#[inline(always)]
340-
fn by_ref(&mut self) -> &Self {
340+
fn by_ref(&self) -> &Self {
341341
self
342342
}
343343
}

0 commit comments

Comments
 (0)