0
0
mirror of https://github.com/rust-lang/rust.git synced 2024-12-01 13:18:54 +01:00
rust/library/core
Guillaume Gomez 305ca05cbe
Rollup merge of #132459 - RalfJung:byte_sub_ptr, r=scottmcm
feat(byte_sub_ptr): unstably add ptr::byte_sub_ptr

This is an API that naturally should exist as a combination of byte_offset_from and sub_ptr
both existing (they showed up at similar times so this union was never made). Adding these
is a logical (and perhaps final) precondition of stabilizing ptr_sub_ptr (https://github.com/rust-lang/rust/issues/95892).

Original PR by ``@Gankra`` (https://github.com/rust-lang/rust/pull/121919), I am just reviving it. The 2nd commit (with a small docs tweak) is by me.
2024-11-02 03:08:56 +08:00
..
benches
src Rollup merge of #132459 - RalfJung:byte_sub_ptr, r=scottmcm 2024-11-02 03:08:56 +08:00
tests Rollup merge of #131391 - ChaiTRex:isqrt, r=scottmcm,tgross35 2024-10-28 12:14:57 +01:00
Cargo.toml