diff options
| author | blitzerr <rusty.blitzerr@gmail.com> | 2020-09-22 06:22:02 -0700 |
|---|---|---|
| committer | blitzerr <rusty.blitzerr@gmail.com> | 2020-09-22 06:22:02 -0700 |
| commit | 3ffd403c6b97f181c189a8eb5fbd30e3e7a95b43 (patch) | |
| tree | 23200238b60848d20c1e78f486c97fdbcce997ff /library/std | |
| parent | 219003bd2ee6778333cf92405c6ea8591ecc8816 (diff) | |
| download | rust-3ffd403c6b97f181c189a8eb5fbd30e3e7a95b43.tar.gz rust-3ffd403c6b97f181c189a8eb5fbd30e3e7a95b43.zip | |
removing &mut self for other methods of AllocRef
Diffstat (limited to 'library/std')
| -rw-r--r-- | library/std/src/alloc.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/library/std/src/alloc.rs b/library/std/src/alloc.rs index 86ae4cf4dd2..f41aa28b5ec 100644 --- a/library/std/src/alloc.rs +++ b/library/std/src/alloc.rs @@ -207,12 +207,12 @@ unsafe impl AllocRef for System { } #[inline] - fn alloc_zeroed(&mut self, layout: Layout) -> Result<NonNull<[u8]>, AllocErr> { + fn alloc_zeroed(&self, layout: Layout) -> Result<NonNull<[u8]>, AllocErr> { self.alloc_impl(layout, true) } #[inline] - unsafe fn dealloc(&mut self, ptr: NonNull<u8>, layout: Layout) { + unsafe fn dealloc(&self, ptr: NonNull<u8>, layout: Layout) { if layout.size() != 0 { // SAFETY: `layout` is non-zero in size, // other conditions must be upheld by the caller |
