Skip to content

Commit ab55ecf

Browse files
authored
Rollup merge of #57314 - wiktorkuchta:master, r=Centril
Fix repeated word typos Inspired by #57295 (I skipped 'be be' because of it) and my [PR in another repo ](cp-algorithms/cp-algorithms#389) Not a stupid `sed`, I actually tried to fix case by case.
2 parents 676b0b0 + 06243b1 commit ab55ecf

File tree

18 files changed

+32
-32
lines changed

18 files changed

+32
-32
lines changed

src/doc/rustc/src/lints/listing/warn-by-default.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ warning: attempt to add with overflow
2424

2525
## dead-code
2626

27-
This lint detects detect unused, unexported items. Some
27+
This lint detects unused, unexported items. Some
2828
example code that triggers this lint:
2929

3030
```rust
@@ -44,7 +44,7 @@ warning: function is never used: `foo`
4444

4545
## deprecated
4646

47-
This lint detects detects use of deprecated items. Some
47+
This lint detects use of deprecated items. Some
4848
example code that triggers this lint:
4949

5050
```rust
@@ -119,7 +119,7 @@ warning: found struct without foreign-function-safe representation annotation in
119119

120120
## late-bound-lifetime-arguments
121121

122-
This lint detects detects generic lifetime arguments in path segments with
122+
This lint detects generic lifetime arguments in path segments with
123123
late bound lifetime parameters. Some example code that triggers this lint:
124124

125125
```rust
@@ -381,7 +381,7 @@ extern crate macro_crate_test;
381381

382382
## private-in-public
383383

384-
This lint detects detect private items in public interfaces not caught by the old implementation. Some
384+
This lint detects private items in public interfaces not caught by the old implementation. Some
385385
example code that triggers this lint:
386386

387387
```rust,ignore
@@ -659,7 +659,7 @@ warning: unknown lint: `not_a_real_lint`
659659

660660
## unreachable-code
661661

662-
This lint detects detects unreachable code paths. Some example code that
662+
This lint detects unreachable code paths. Some example code that
663663
triggers this lint:
664664

665665
```rust,no_run
@@ -681,7 +681,7 @@ warning: unreachable statement
681681

682682
## unreachable-patterns
683683

684-
This lint detects detects unreachable patterns. Some
684+
This lint detects unreachable patterns. Some
685685
example code that triggers this lint:
686686

687687
```rust
@@ -716,11 +716,11 @@ annotations now.
716716

717717
## unused-allocation
718718

719-
This lint detects detects unnecessary allocations that can be eliminated.
719+
This lint detects unnecessary allocations that can be eliminated.
720720

721721
## unused-assignments
722722

723-
This lint detects detect assignments that will never be read. Some
723+
This lint detects assignments that will never be read. Some
724724
example code that triggers this lint:
725725

726726
```rust
@@ -741,7 +741,7 @@ warning: value assigned to `x` is never read
741741

742742
## unused-attributes
743743

744-
This lint detects detects attributes that were not used by the compiler. Some
744+
This lint detects attributes that were not used by the compiler. Some
745745
example code that triggers this lint:
746746

747747
```rust
@@ -785,7 +785,7 @@ warning: comparison is useless due to type limits
785785

786786
## unused-doc-comment
787787

788-
This lint detects detects doc comments that aren't used by rustdoc. Some
788+
This lint detects doc comments that aren't used by rustdoc. Some
789789
example code that triggers this lint:
790790

791791
```rust
@@ -831,7 +831,7 @@ warning: unused import: `std::collections::HashMap`
831831

832832
## unused-macros
833833

834-
This lint detects detects macros that were not used. Some example code that
834+
This lint detects macros that were not used. Some example code that
835835
triggers this lint:
836836

837837
```rust
@@ -884,7 +884,7 @@ warning: unused `std::result::Result` that must be used
884884

885885
## unused-mut
886886

887-
This lint detects detect mut variables which don't need to be mutable. Some
887+
This lint detects mut variables which don't need to be mutable. Some
888888
example code that triggers this lint:
889889

890890
```rust
@@ -946,7 +946,7 @@ warning: unnecessary `unsafe` block
946946

947947
## unused-variables
948948

949-
This lint detects detect variables which are not used in any way. Some
949+
This lint detects variables which are not used in any way. Some
950950
example code that triggers this lint:
951951

952952
```rust

src/doc/rustdoc/src/documentation-tests.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ compiles, while only showing the parts that are relevant to that part of your
171171
explanation.
172172
173173
The `#`-hiding of lines can be prevented by using two consecutive hashes
174-
`##`. This only needs to be done with with the first `#` which would've
174+
`##`. This only needs to be done with the first `#` which would've
175175
otherwise caused hiding. If we have a string literal like the following,
176176
which has a line that starts with a `#`:
177177

src/librustc/infer/opaque_types/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ pub type OpaqueTypeMap<'tcx> = DefIdMap<OpaqueTypeDecl<'tcx>>;
1919
/// appear in the return type).
2020
#[derive(Copy, Clone, Debug)]
2121
pub struct OpaqueTypeDecl<'tcx> {
22-
/// The substitutions that we apply to the abstract that that this
22+
/// The substitutions that we apply to the abstract that this
2323
/// `impl Trait` desugars to. e.g., if:
2424
///
2525
/// fn foo<'a, 'b, T>() -> impl Trait<'a>

src/librustc/mir/interpret/value.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ pub enum Scalar<Tag=(), Id=AllocId> {
7979
/// The raw bytes of a simple value.
8080
Bits {
8181
/// The first `size` bytes are the value.
82-
/// Do not try to read less or more bytes that that. The remaining bytes must be 0.
82+
/// Do not try to read less or more bytes than that. The remaining bytes must be 0.
8383
size: u8,
8484
bits: u128,
8585
},

src/librustc/ty/fold.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ pub trait TypeFoldable<'tcx>: fmt::Debug + Clone {
109109
self.has_type_flags(TypeFlags::HAS_FREE_REGIONS)
110110
}
111111

112-
/// True if there any any un-erased free regions.
112+
/// True if there are any un-erased free regions.
113113
fn has_erasable_regions(&self) -> bool {
114114
self.has_type_flags(TypeFlags::HAS_FREE_REGIONS)
115115
}

src/librustc_apfloat/ieee.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2341,7 +2341,7 @@ mod sig {
23412341
// Our exponent should not underflow.
23422342
*exp = exp.checked_sub(bits as ExpInt).unwrap();
23432343

2344-
// Jump is the inter-limb jump; shift is is intra-limb shift.
2344+
// Jump is the inter-limb jump; shift is the intra-limb shift.
23452345
let jump = bits / LIMB_BITS;
23462346
let shift = bits % LIMB_BITS;
23472347

@@ -2375,7 +2375,7 @@ mod sig {
23752375
// Our exponent should not overflow.
23762376
*exp = exp.checked_add(bits as ExpInt).unwrap();
23772377

2378-
// Jump is the inter-limb jump; shift is is intra-limb shift.
2378+
// Jump is the inter-limb jump; shift is the intra-limb shift.
23792379
let jump = bits / LIMB_BITS;
23802380
let shift = bits % LIMB_BITS;
23812381

src/librustc_lint/builtin.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -673,7 +673,7 @@ impl EarlyLintPass for AnonymousParameters {
673673
}
674674
}
675675

676-
/// Checks for incorrect use use of `repr` attributes.
676+
/// Checks for incorrect use of `repr` attributes.
677677
#[derive(Clone)]
678678
pub struct BadRepr;
679679

src/librustc_resolve/diagnostics.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ use foo::core; // error: an extern crate named `core` has already
192192
fn main() {}
193193
```
194194
195-
To fix issue issue, you have to rename at least one of the two imports.
195+
To fix this issue, you have to rename at least one of the two imports.
196196
Example:
197197
198198
```

src/librustc_typeck/astconv.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//! Conversion from AST representation of types to the `ty.rs` representation.
2-
//! The main routine here is `ast_ty_to_ty()`; each use is is parameterized by
3-
//! an instance of `AstConv`.
2+
//! The main routine here is `ast_ty_to_ty()`; each use is parameterized by an
3+
//! instance of `AstConv`.
44
55
use errors::{Applicability, FatalError, DiagnosticId};
66
use hir::{self, GenericArg, GenericArgs};

src/librustc_typeck/check/demand.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> {
335335
// we may want to suggest adding a `*`, or removing
336336
// a `&`.
337337
//
338-
// (But, also check check the `expn_info()` to see if this is
338+
// (But, also check the `expn_info()` to see if this is
339339
// a macro; if so, it's hard to extract the text and make a good
340340
// suggestion, so don't bother.)
341341
if self.infcx.can_sub(self.param_env, checked, &expected).is_ok() &&

0 commit comments

Comments
 (0)