File tree 1 file changed +4
-0
lines changed
1 file changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -574,6 +574,8 @@ pub const fn null_mut<T: ?Sized + Thin>() -> *mut T {
574
574
575
575
/// Creates a pointer with the given address and no provenance.
576
576
///
577
+ /// This is equivalent to `ptr::null().with_addr(addr)`.
578
+ ///
577
579
/// Without provenance, this pointer is not associated with any actual allocation. Such a
578
580
/// no-provenance pointer may be used for zero-sized memory accesses (if suitably aligned), but
579
581
/// non-zero-sized memory accesses with a no-provenance pointer are UB. No-provenance pointers are
@@ -616,6 +618,8 @@ pub const fn dangling<T>() -> *const T {
616
618
617
619
/// Creates a pointer with the given address and no provenance.
618
620
///
621
+ /// This is equivalent to `ptr::null_mut().with_addr(addr)`.
622
+ ///
619
623
/// Without provenance, this pointer is not associated with any actual allocation. Such a
620
624
/// no-provenance pointer may be used for zero-sized memory accesses (if suitably aligned), but
621
625
/// non-zero-sized memory accesses with a no-provenance pointer are UB. No-provenance pointers are
You can’t perform that action at this time.
0 commit comments