Skip to content

Commit c154757

Browse files
committed
more dupe word typos
1 parent 3a210b8 commit c154757

File tree

11 files changed

+16
-16
lines changed

11 files changed

+16
-16
lines changed

alloc/src/collections/linked_list.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1613,7 +1613,7 @@ impl<'a, T> CursorMut<'a, T> {
16131613
None
16141614
} else {
16151615
// We can't point to the node that we pop. Copying the behavior of
1616-
// `remove_current`, we move on the the next node in the sequence.
1616+
// `remove_current`, we move on to the next node in the sequence.
16171617
// If the list is of length 1 then we end pointing to the "ghost"
16181618
// node at index 0, which is expected.
16191619
if self.list.head == self.current {

core/src/iter/traits/iterator.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -692,7 +692,7 @@ pub trait Iterator {
692692
/// assert_eq!(it.next(), Some(NotClone(99))); // The separator.
693693
/// assert_eq!(it.next(), Some(NotClone(1))); // The next element from `v`.
694694
/// assert_eq!(it.next(), Some(NotClone(99))); // The separator.
695-
/// assert_eq!(it.next(), Some(NotClone(2))); // The last element from from `v`.
695+
/// assert_eq!(it.next(), Some(NotClone(2))); // The last element from `v`.
696696
/// assert_eq!(it.next(), None); // The iterator is finished.
697697
/// ```
698698
///

core/src/mem/maybe_uninit.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -647,7 +647,7 @@ impl<T> MaybeUninit<T> {
647647
/// implements the [`Copy`] trait or not. When using multiple copies of the
648648
/// data (by calling `assume_init_read` multiple times, or first calling
649649
/// `assume_init_read` and then [`assume_init`]), it is your responsibility
650-
/// to ensure that that data may indeed be duplicated.
650+
/// to ensure that data may indeed be duplicated.
651651
///
652652
/// [inv]: #initialization-invariant
653653
/// [`assume_init`]: MaybeUninit::assume_init

core/src/num/dec2flt/lemire.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ pub fn compute_float<F: RawFloat>(q: i64, mut w: u64) -> BiasedFp {
7676
return BiasedFp { f: mantissa, e: power2 };
7777
}
7878
// Need to handle rounding ties. Normally, we need to round up,
79-
// but if we fall right in between and and we have an even basis, we
79+
// but if we fall right in between and we have an even basis, we
8080
// need to round down.
8181
//
8282
// This will only occur if:

core/src/num/int_log10.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/// These functions compute the integer logarithm of their type, assuming
2-
/// that someone has already checked that the the value is strictly positive.
2+
/// that someone has already checked that the value is strictly positive.
33
44
// 0 < val <= u8::MAX
55
#[inline]

core/src/ptr/const_ptr.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -694,7 +694,7 @@ impl<T: ?Sized> *const T {
694694
/// units of T: the distance in bytes is divided by `mem::size_of::<T>()`.
695695
///
696696
/// This computes the same value that [`offset_from`](#method.offset_from)
697-
/// would compute, but with the added precondition that that the offset is
697+
/// would compute, but with the added precondition that the offset is
698698
/// guaranteed to be non-negative. This method is equivalent to
699699
/// `usize::from(self.offset_from(origin)).unwrap_unchecked()`,
700700
/// but it provides slightly more information to the optimizer, which can

core/src/ptr/mut_ptr.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -867,7 +867,7 @@ impl<T: ?Sized> *mut T {
867867
/// units of T: the distance in bytes is divided by `mem::size_of::<T>()`.
868868
///
869869
/// This computes the same value that [`offset_from`](#method.offset_from)
870-
/// would compute, but with the added precondition that that the offset is
870+
/// would compute, but with the added precondition that the offset is
871871
/// guaranteed to be non-negative. This method is equivalent to
872872
/// `usize::from(self.offset_from(origin)).unwrap_unchecked()`,
873873
/// but it provides slightly more information to the optimizer, which can

core/src/sync/atomic.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1642,8 +1642,8 @@ impl<T> AtomicPtr<T> {
16421642
/// and the argument `val`, and stores a pointer with provenance of the
16431643
/// current pointer and the resulting address.
16441644
///
1645-
/// This is equivalent equivalent to using [`map_addr`] to atomically
1646-
/// perform `ptr = ptr.map_addr(|a| a | val)`. This can be used in tagged
1645+
/// This is equivalent to using [`map_addr`] to atomically perform
1646+
/// `ptr = ptr.map_addr(|a| a | val)`. This can be used in tagged
16471647
/// pointer schemes to atomically set tag bits.
16481648
///
16491649
/// **Caveat**: This operation returns the previous value. To compute the
@@ -1693,8 +1693,8 @@ impl<T> AtomicPtr<T> {
16931693
/// pointer, and the argument `val`, and stores a pointer with provenance of
16941694
/// the current pointer and the resulting address.
16951695
///
1696-
/// This is equivalent equivalent to using [`map_addr`] to atomically
1697-
/// perform `ptr = ptr.map_addr(|a| a & val)`. This can be used in tagged
1696+
/// This is equivalent to using [`map_addr`] to atomically perform
1697+
/// `ptr = ptr.map_addr(|a| a & val)`. This can be used in tagged
16981698
/// pointer schemes to atomically unset tag bits.
16991699
///
17001700
/// **Caveat**: This operation returns the previous value. To compute the
@@ -1743,8 +1743,8 @@ impl<T> AtomicPtr<T> {
17431743
/// pointer, and the argument `val`, and stores a pointer with provenance of
17441744
/// the current pointer and the resulting address.
17451745
///
1746-
/// This is equivalent equivalent to using [`map_addr`] to atomically
1747-
/// perform `ptr = ptr.map_addr(|a| a ^ val)`. This can be used in tagged
1746+
/// This is equivalent to using [`map_addr`] to atomically perform
1747+
/// `ptr = ptr.map_addr(|a| a ^ val)`. This can be used in tagged
17481748
/// pointer schemes to atomically toggle tag bits.
17491749
///
17501750
/// **Caveat**: This operation returns the previous value. To compute the

core/tests/num/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ fn test_can_not_overflow() {
172172

173173
// Calcutate the string length for the smallest overflowing number:
174174
let max_len_string = format_radix(num, base as u128);
175-
// Ensure that that string length is deemed to potentially overflow:
175+
// Ensure that string length is deemed to potentially overflow:
176176
assert!(can_overflow::<$t>(base, &max_len_string));
177177
}
178178
)*)

std/src/process.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1629,7 +1629,7 @@ impl ExitStatusError {
16291629
///
16301630
/// This is exactly like [`code()`](Self::code), except that it returns a `NonZeroI32`.
16311631
///
1632-
/// Plain `code`, returning a plain integer, is provided because is is often more convenient.
1632+
/// Plain `code`, returning a plain integer, is provided because it is often more convenient.
16331633
/// The returned value from `code()` is indeed also nonzero; use `code_nonzero()` when you want
16341634
/// a type-level guarantee of nonzeroness.
16351635
///

0 commit comments

Comments
 (0)