Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions library/core/src/ptr/non_null.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ use crate::{fmt, hash, intrinsics, mem, ptr};
///
/// # Representation
///
/// `NonNull<T>` is guaranteed to be ABI-compatible with `*const T`,
/// `*mut T`, `&T`, `&mut T`, and `Box<T, Global>` for all `T`, but its
/// pointer must not be null.
///
/// Thanks to the [null pointer optimization],
/// `NonNull<T>` and `Option<NonNull<T>>`
/// are guaranteed to have the same size and alignment:
Expand Down
Loading