mirror of
https://github.com/allankoechke/rust.git
synced 2026-12-03 09:32:42 +00:00
Implement `Box::as_non_null()`. ACP: <https://github.com/rust-lang/libs-team/issues/799> Tracking issue: <https://github.com/rust-lang/rust/issues/157345> The docs are mostly copied from `Box::as_mut_ptr()` I also made a drive-by change to add `#[must_use]` to `Box::as_{ptr, mut_ptr}`. I'm unsure what `#[rustc_never_returns_null_ptr]` and `#[rustc_as_ptr]` do. Should `Box::as_non_null()` be annotated with them? r? libs-api