Skip to content

Commit 935958e

Browse files
authored
Rollup merge of rust-lang#98541 - Veykril:patch-2, r=Dylan-DPC
Update `std::alloc::System` doc example code style `return` on the last line of a block is unidiomatic so I don't think the example should be using that here
2 parents 93ea1ec + 756118e commit 935958e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/std/src/alloc.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ pub use alloc_crate::alloc::*;
102102
/// if !ret.is_null() {
103103
/// ALLOCATED.fetch_add(layout.size(), SeqCst);
104104
/// }
105-
/// return ret
105+
/// ret
106106
/// }
107107
///
108108
/// unsafe fn dealloc(&self, ptr: *mut u8, layout: Layout) {

0 commit comments

Comments
 (0)