rust/library
bors 7e4f4660eb Auto merge of #104977 - RalfJung:ptr-from-ref, r=dtolnay
add ptr::from_{ref,mut}

We have methods to avoid almost all `as` casts around raw pointer handling, except for the initial cast from reference to raw pointer. These new methods close that gap.

(I also moved `null_mut` next to `null` to keep the file consistently organized.)

r? libs-api

Tracking issue: https://github.com/rust-lang/rust/issues/106116
2022-12-24 17:14:26 +00:00
..
alloc fix one more unaligned self.ptr, and add tests 2022-12-23 15:49:23 +01:00
backtrace@07872f28cd
core Auto merge of #104977 - RalfJung:ptr-from-ref, r=dtolnay 2022-12-24 17:14:26 +00:00
panic_abort
panic_unwind
portable-simd
proc_macro Add a "the" to proc_macro documentation 2022-12-12 16:19:18 +01:00
profiler_builtins
rtstartup
rustc-std-workspace-alloc
rustc-std-workspace-core
rustc-std-workspace-std
std std: only use LFS function on glibc 2022-12-22 16:01:27 +08:00
stdarch@790411f93c
test Fix uninlined_format_args in libtest 2022-12-19 08:58:40 +01:00
unwind