diff options
| author | bors <bors@rust-lang.org> | 2018-08-21 16:04:11 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2018-08-21 16:04:11 +0000 |
| commit | 9f9f2c0095cd683b94adca133f2733aa1f88bb19 (patch) | |
| tree | 633b85f8126a21ae60807bede94f1c57c5167a6a /src/liballoc_system | |
| parent | a9d496796f091f42c8bac60c5c9ca05e6ca5dcda (diff) | |
| parent | e3887e6c8afbaafe0332e9776199bc89030e227b (diff) | |
| download | rust-9f9f2c0095cd683b94adca133f2733aa1f88bb19.tar.gz rust-9f9f2c0095cd683b94adca133f2733aa1f88bb19.zip | |
Auto merge of #53530 - kennytm:rollup, r=kennytm
Rollup of 17 pull requests
Successful merges:
- #53030 (Updated RELEASES.md for 1.29.0)
- #53104 (expand the documentation on the `Unpin` trait)
- #53213 (Stabilize IP associated constants)
- #53296 (When closure with no arguments was expected, suggest wrapping)
- #53329 (Replace usages of ptr::offset with ptr::{add,sub}.)
- #53363 (add individual docs to `core::num::NonZero*`)
- #53370 (Stabilize macro_vis_matcher)
- #53393 (Mark libserialize functions as inline)
- #53405 (restore the page title after escaping out of a search)
- #53452 (Change target triple used to check for lldb in build-manifest)
- #53462 (Document Box::into_raw returns non-null ptr)
- #53465 (Remove LinkMeta struct)
- #53492 (update lld submodule to include RISCV patch)
- #53496 (Fix typos found by codespell.)
- #53521 (syntax: Optimize some literal parsing)
- #53540 (Moved issue-53157.rs into src/test/ui/consts/const-eval/)
- #53551 (Avoid some Place clones.)
Failed merges:
r? @ghost
Diffstat (limited to 'src/liballoc_system')
| -rw-r--r-- | src/liballoc_system/lib.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/liballoc_system/lib.rs b/src/liballoc_system/lib.rs index c5e056f6b12..753b6a5e292 100644 --- a/src/liballoc_system/lib.rs +++ b/src/liballoc_system/lib.rs @@ -249,7 +249,7 @@ mod platform { } unsafe fn align_ptr(ptr: *mut u8, align: usize) -> *mut u8 { - let aligned = ptr.offset((align - (ptr as usize & (align - 1))) as isize); + let aligned = ptr.add(align - (ptr as usize & (align - 1))); *get_header(aligned) = Header(ptr); aligned } |
