Skip to content

Commit 9af3eec

Browse files
authored
Rollup merge of rust-lang#67154 - kraai:alloc-typos, r=Dylan-DPC
Fix typos in src/libcore/alloc.rs docs
2 parents 071acdf + 9e8505d commit 9af3eec

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/libcore/alloc.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ impl Layout {
253253

254254
/// Creates a layout describing the record for `self` followed by
255255
/// `next`, including any necessary padding to ensure that `next`
256-
/// will be properly aligned. Note that the result layout will
256+
/// will be properly aligned. Note that the resulting layout will
257257
/// satisfy the alignment properties of both `self` and `next`.
258258
///
259259
/// The resulting layout will be the same as that of a C struct containing
@@ -387,7 +387,7 @@ impl fmt::Display for CannotReallocInPlace {
387387
}
388388

389389
/// A memory allocator that can be registered as the standard library’s default
390-
/// though the `#[global_allocator]` attributes.
390+
/// through the `#[global_allocator]` attribute.
391391
///
392392
/// Some of the methods require that a memory block be *currently
393393
/// allocated* via an allocator. This means that:
@@ -458,7 +458,7 @@ pub unsafe trait GlobalAlloc {
458458
/// # Errors
459459
///
460460
/// Returning a null pointer indicates that either memory is exhausted
461-
/// or `layout` does not meet allocator's size or alignment constraints.
461+
/// or `layout` does not meet this allocator's size or alignment constraints.
462462
///
463463
/// Implementations are encouraged to return null on memory
464464
/// exhaustion rather than aborting, but this is not
@@ -1045,7 +1045,7 @@ pub unsafe trait Alloc {
10451045
/// Captures a common usage pattern for allocators.
10461046
///
10471047
/// The returned block is suitable for passing to the
1048-
/// `alloc`/`realloc` methods of this allocator.
1048+
/// `realloc`/`dealloc` methods of this allocator.
10491049
///
10501050
/// Note to implementors: If this returns `Ok(ptr)`, then `ptr`
10511051
/// must be considered "currently allocated" and must be
@@ -1111,7 +1111,7 @@ pub unsafe trait Alloc {
11111111
/// Captures a common usage pattern for allocators.
11121112
///
11131113
/// The returned block is suitable for passing to the
1114-
/// `alloc`/`realloc` methods of this allocator.
1114+
/// `realloc`/`dealloc` methods of this allocator.
11151115
///
11161116
/// Note to implementors: If this returns `Ok(ptr)`, then `ptr`
11171117
/// must be considered "currently allocated" and must be
@@ -1158,7 +1158,7 @@ pub unsafe trait Alloc {
11581158
/// Captures a common usage pattern for allocators.
11591159
///
11601160
/// The returned block is suitable for passing to the
1161-
/// `alloc`/`realloc` methods of this allocator.
1161+
/// `realloc`/`dealloc` methods of this allocator.
11621162
///
11631163
/// # Safety
11641164
///

0 commit comments

Comments
 (0)