Rollup merge of #127230 - hattizai:patch01, r=saethlin · model-checking/verify-rust-std@a8b6d0a (original) (raw)
6 files changed
lines changed
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -230,7 +230,7 @@ pub struct AssertParamIsCopy<T: Copy + ?Sized> { | ||
230 | 230 | pub unsafe trait CloneToUninit { |
231 | 231 | /// Performs copy-assignment from `self` to `dst`. |
232 | 232 | /// |
233 | - /// This is analogous to to `std::ptr::write(dst, self.clone())`, | |
233 | + /// This is analogous to `std::ptr::write(dst, self.clone())`, | |
234 | 234 | /// except that `self` may be a dynamically-sized type ([`!Sized`](Sized)). |
235 | 235 | /// |
236 | 236 | /// Before this function is called, `dst` may point to uninitialized memory. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -159,7 +159,7 @@ pub(crate) struct GenericShunt<'a, I, R> { | ||
159 | 159 | residual: &'a mut Option<R>, |
160 | 160 | } |
161 | 161 | |
162 | -/// Process the given iterator as if it yielded a the item's `Try::Output` | |
162 | +/// Process the given iterator as if it yielded the item's `Try::Output` | |
163 | 163 | /// type instead. Any `Try::Residual`s encountered will stop the inner iterator |
164 | 164 | /// and be propagated back to the overall result. |
165 | 165 | pub(crate) fn try_process<I, T, R, F, U>(iter: I, mut f: F) -> ChangeOutputType<I::Item, U> |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -157,7 +157,7 @@ fn compute_product_approx(q: i64, w: u64, precision: usize) -> (u64, u64) { | ||
157 | 157 | // Need to do a second multiplication to get better precision |
158 | 158 | // for the lower product. This will always be exact |
159 | 159 | // where q is < 55, since 5^55 < 2^128. If this wraps, |
160 | -// then we need to need to round up the hi product. | |
160 | +// then we need to round up the hi product. | |
161 | 161 | let (_, second_hi) = full_multiplication(w, hi5); |
162 | 162 | first_lo = first_lo.wrapping_add(second_hi); |
163 | 163 | if second_hi > first_lo { |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -28,7 +28,7 @@ | ||
28 | 28 | //! |
29 | 29 | //! # Layout |
30 | 30 | //! Tagged values are 64 bits, with the 2 least significant bits used for the |
31 | -//! tag. This means there are there are 4 "variants": | |
31 | +//! tag. This means there are 4 "variants": | |
32 | 32 | //! |
33 | 33 | //! - **Tag 0b00**: The first variant is equivalent to |
34 | 34 | //! `ErrorData::SimpleMessage`, and holds a `&'static SimpleMessage` directly. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -183,7 +183,7 @@ mod imp { | ||
183 | 183 | // Use `_NSGetArgc` and `_NSGetArgv` on Apple platforms. |
184 | 184 | // |
185 | 185 | // Even though these have underscores in their names, they've been available |
186 | -// since since the first versions of both macOS and iOS, and are declared in | |
186 | +// since the first versions of both macOS and iOS, and are declared in | |
187 | 187 | // the header `crt_externs.h`. |
188 | 188 | // |
189 | 189 | // NOTE: This header was added to the iOS 13.0 SDK, which has been the source |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -190,7 +190,7 @@ unsafe fn allocate(layout: Layout, zeroed: bool) -> *mut u8 { | ||
190 | 190 | // it, it is safe to write a header directly before it. |
191 | 191 | unsafe { ptr::write((aligned as *mut Header).sub(1), Header(ptr)) }; |
192 | 192 | |
193 | -// SAFETY: The returned pointer does not point to the to the start of an allocated block, | |
193 | +// SAFETY: The returned pointer does not point to the start of an allocated block, | |
194 | 194 | // but there is a header readable directly before it containing the location of the start |
195 | 195 | // of the block. |
196 | 196 | aligned |