File tree 2 files changed +4
-4
lines changed
2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -647,8 +647,8 @@ impl<T: ?Sized> *const T {
647
647
/// such large allocations either.)
648
648
///
649
649
/// The requirement for pointers to be derived from the same allocated object is primarily
650
- /// needed for `const`-compatibility: at compile-time, pointers into *different* allocated
651
- /// objects do not have a known distance to each other . However, the requirement also exists at
650
+ /// needed for `const`-compatibility: the distance between pointers into *different* allocated
651
+ /// objects is not known at compile-time . However, the requirement also exists at
652
652
/// runtime and may be exploited by optimizations. If you wish to compute the difference between
653
653
/// pointers that are not guaranteed to be from the same allocation, use `(self as
654
654
/// usize).sub(origin as usize) / mem::size_of::<T>()`.
Original file line number Diff line number Diff line change @@ -819,8 +819,8 @@ impl<T: ?Sized> *mut T {
819
819
/// such large allocations either.)
820
820
///
821
821
/// The requirement for pointers to be derived from the same allocated object is primarily
822
- /// needed for `const`-compatibility: at compile-time, pointers into *different* allocated
823
- /// objects do not have a known distance to each other . However, the requirement also exists at
822
+ /// needed for `const`-compatibility: the distance between pointers into *different* allocated
823
+ /// objects is not known at compile-time . However, the requirement also exists at
824
824
/// runtime and may be exploited by optimizations. If you wish to compute the difference between
825
825
/// pointers that are not guaranteed to be from the same allocation, use `(self as
826
826
/// usize).sub(origin as usize) / mem::size_of::<T>()`.
You can’t perform that action at this time.
0 commit comments