Skip to content

Commit e8f7cc9

Browse files
authored
Use align up instead of overaligned
1 parent d175b3e commit e8f7cc9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

library/core/src/ptr/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2166,10 +2166,10 @@ pub unsafe fn write_volatile<T>(dst: *mut T, src: T) {
21662166
}
21672167
}
21682168

2169-
/// Calculate an offset to pointer `p` overaligned to alignment `a`.
2169+
/// Calculate an offset to pointer `p` that aligns it up to alignment `a`.
21702170
///
21712171
/// Calculate offset (in terms of elements of `size_of::<T>()` stride) that has to be added
2172-
/// to pointer `p` so that pointer `p` would get overaligned to `a`.
2172+
/// to pointer `p` so that pointer `p` would get aligned up to `a`.
21732173
///
21742174
/// # Safety
21752175
/// `a` must be a power of two.

0 commit comments

Comments
 (0)