diff options
| author | Adrian Palacios <accorell@amazon.com> | 2022-05-02 14:41:21 +0000 |
|---|---|---|
| committer | Adrian Palacios <accorell@amazon.com> | 2022-05-02 14:41:21 +0000 |
| commit | 9b36a4783101c86a7b6597804e59dae076459653 (patch) | |
| tree | 6ae030213981bf36be25add8821e6b576723b85c | |
| parent | 542898328637b31412d91b882ce0dc4b85ad54e6 (diff) | |
| download | rust-9b36a4783101c86a7b6597804e59dae076459653.tar.gz rust-9b36a4783101c86a7b6597804e59dae076459653.zip | |
Fix typo in `offset_from` documentation
| -rw-r--r-- | library/core/src/ptr/const_ptr.rs | 2 | ||||
| -rw-r--r-- | library/core/src/ptr/mut_ptr.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/library/core/src/ptr/const_ptr.rs b/library/core/src/ptr/const_ptr.rs index 7ef2e95542b..45964c3a444 100644 --- a/library/core/src/ptr/const_ptr.rs +++ b/library/core/src/ptr/const_ptr.rs @@ -518,7 +518,7 @@ impl<T: ?Sized> *const T { } /// Calculates the distance between two pointers. The returned value is in - /// units of T: the distance in bytes is divided by `mem::size_of::<T>()`. + /// units of T: the distance in bytes divided by `mem::size_of::<T>()`. /// /// This function is the inverse of [`offset`]. /// diff --git a/library/core/src/ptr/mut_ptr.rs b/library/core/src/ptr/mut_ptr.rs index 56f9c84f5af..ff5207c1a06 100644 --- a/library/core/src/ptr/mut_ptr.rs +++ b/library/core/src/ptr/mut_ptr.rs @@ -696,7 +696,7 @@ impl<T: ?Sized> *mut T { } /// Calculates the distance between two pointers. The returned value is in - /// units of T: the distance in bytes is divided by `mem::size_of::<T>()`. + /// units of T: the distance in bytes divided by `mem::size_of::<T>()`. /// /// This function is the inverse of [`offset`]. /// |
