Skip to content

Commit 5160f8f

Browse files
committed
Spellchecking compiler comments
This PR cleans up the rest of the spelling mistakes in the compiler comments. This PR does not change any literal or code spelling issues.
1 parent 3e75146 commit 5160f8f

File tree

116 files changed

+171
-171
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

116 files changed

+171
-171
lines changed

compiler/rustc_apfloat/src/ieee.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2646,7 +2646,7 @@ mod sig {
26462646

26472647
// Convert the result having "2 * precision" significant-bits back to the one
26482648
// having "precision" significant-bits. First, move the radix point from
2649-
// poision "2*precision - 1" to "precision - 1". The exponent need to be
2649+
// position "2*precision - 1" to "precision - 1". The exponent need to be
26502650
// adjusted by "2*precision - 1" - "precision - 1" = "precision".
26512651
*exp -= precision as ExpInt + 1;
26522652

compiler/rustc_ast/src/tokenstream.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ impl AttrAnnotatedTokenStream {
295295
///
296296
/// For example, `#[cfg(FALSE)] struct Foo {}` would
297297
/// have an `attrs` field containing the `#[cfg(FALSE)]` attr,
298-
/// and a `tokens` field storing the (unparesd) tokens `struct Foo {}`
298+
/// and a `tokens` field storing the (unparsed) tokens `struct Foo {}`
299299
#[derive(Clone, Debug, Encodable, Decodable)]
300300
pub struct AttributesData {
301301
/// Attributes, both outer and inner.

compiler/rustc_borrowck/src/type_check/relate_tys.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ impl<'tcx> TypeRelatingDelegate<'tcx> for NllTypeRelatingDelegate<'_, '_, 'tcx>
158158
.infcx
159159
.handle_opaque_type(a, b, a_is_expected, &cause, param_env)?
160160
.obligations,
161-
// These fields are filled in during exectuion of the operation
161+
// These fields are filled in during execution of the operation
162162
base_universe: None,
163163
region_constraints: None,
164164
},

compiler/rustc_codegen_cranelift/src/pretty_clif.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
//! ss2 = explicit_slot 8 ; _4: (&&[u16],) size=8 align=8,8
2424
//! sig0 = (i64, i64, i64) system_v
2525
//! sig1 = (i64, i64, i64) system_v
26-
//! fn0 = colocated u0:6 sig1 ; Instance { def: Item(DefId(0/0:31 ~ example[8787]::{{impl}}[1]::call_mut[0])), substs: [ReErased, ReErased] }
26+
//! fn0 = collocated u0:6 sig1 ; Instance { def: Item(DefId(0/0:31 ~ example[8787]::{{impl}}[1]::call_mut[0])), substs: [ReErased, ReErased] }
2727
//!
2828
//! block0(v0: i64, v1: i64, v2: i64):
2929
//! v3 = stack_addr.i64 ss0

compiler/rustc_codegen_ssa/src/back/write.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -779,7 +779,7 @@ pub fn compute_per_cgu_lto_type(
779779
// we'll encounter later.
780780
let is_allocator = module_kind == ModuleKind::Allocator;
781781

782-
// We ignore a request for full crate grath LTO if the cate type
782+
// We ignore a request for full crate graph LTO if the crate type
783783
// is only an rlib, as there is no full crate graph to process,
784784
// that'll happen later.
785785
//

compiler/rustc_expand/src/mbe/transcribe.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ enum Frame {
3535
impl Frame {
3636
/// Construct a new frame around the delimited set of tokens.
3737
fn new(mut tts: Vec<mbe::TokenTree>) -> Frame {
38-
// Need to add empty delimeters.
38+
// Need to add empty delimiters.
3939
let open_tt = mbe::TokenTree::token(token::OpenDelim(token::NoDelim), DUMMY_SP);
4040
let close_tt = mbe::TokenTree::token(token::CloseDelim(token::NoDelim), DUMMY_SP);
4141
tts.insert(0, open_tt);
@@ -210,7 +210,7 @@ pub(super) fn transcribe<'a>(
210210
));
211211
}
212212
} else {
213-
// 0 is the initial counter (we have done 0 repretitions so far). `len`
213+
// 0 is the initial counter (we have done 0 repetitions so far). `len`
214214
// is the total number of repetitions we should generate.
215215
repeats.push((0, len));
216216

compiler/rustc_index/src/bit_set.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1717,7 +1717,7 @@ impl<R: Idx, C: Idx> SparseBitMatrix<R, C> {
17171717
if let Some(Some(row)) = self.rows.get(row) { Some(row) } else { None }
17181718
}
17191719

1720-
/// Interescts `row` with `set`. `set` can be either `BitSet` or
1720+
/// Intersects `row` with `set`. `set` can be either `BitSet` or
17211721
/// `HybridBitSet`. Has no effect if `row` does not exist.
17221722
///
17231723
/// Returns true if the row was changed.

compiler/rustc_infer/src/infer/canonical/query_response.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
//! in particular to extract out the resulting region obligations and
33
//! encode them therein.
44
//!
5-
//! For an overview of what canonicaliation is and how it fits into
5+
//! For an overview of what canonicalization is and how it fits into
66
//! rustc, check out the [chapter in the rustc dev guide][c].
77
//!
88
//! [c]: https://rust-lang.github.io/chalk/book/canonical_queries/canonicalization.html

compiler/rustc_infer/src/infer/error_reporting/mod.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1164,7 +1164,7 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
11641164
let len = sub1.len() - common_default_params;
11651165
let consts_offset = len - sub1.consts().count();
11661166

1167-
// Only draw `<...>` if there're lifetime/type arguments.
1167+
// Only draw `<...>` if there are lifetime/type arguments.
11681168
if len > 0 {
11691169
values.0.push_normal("<");
11701170
values.1.push_normal("<");
@@ -1245,7 +1245,7 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
12451245
}
12461246

12471247
// Close the type argument bracket.
1248-
// Only draw `<...>` if there're lifetime/type arguments.
1248+
// Only draw `<...>` if there are lifetime/type arguments.
12491249
if len > 0 {
12501250
values.0.push_normal(">");
12511251
values.1.push_normal(">");
@@ -1857,7 +1857,7 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
18571857
})
18581858
.transpose();
18591859
if output.is_some() {
1860-
// We don't account for multiple `Future::Output = Ty` contraints.
1860+
// We don't account for multiple `Future::Output = Ty` constraints.
18611861
return output;
18621862
}
18631863
}

compiler/rustc_infer/src/infer/lattice.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ where
8383
// But if we did in reverse order, we would create a `v <:
8484
// LHS` (or vice versa) constraint and then instantiate
8585
// `v`. This would require further processing to achieve same
86-
// end-result; in partiular, this screws up some of the logic
86+
// end-result; in particular, this screws up some of the logic
8787
// in coercion, which expects LUB to figure out that the LHS
8888
// is (e.g.) `Box<i32>`. A more obvious solution might be to
8989
// iterate on the subtype obligations that are returned, but I

0 commit comments

Comments
 (0)