Skip to content

Commit

Permalink
chore: remove repetitive words
Browse files Browse the repository at this point in the history
Signed-off-by: cuishuang <imcusg@gmail.com>
  • Loading branch information
cuishuang committed Sep 2, 2024
1 parent 9b82580 commit 8f84aca
Show file tree
Hide file tree
Showing 11 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion compiler/rustc_const_eval/src/interpret/operand.rs
Original file line number Diff line number Diff line change
Expand Up @@ -602,7 +602,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
})
}

/// Read an immediate from a place, asserting that that is possible with the given layout.
/// Read an immediate from a place, asserting that is possible with the given layout.
///
/// If this succeeds, the `ImmTy` is never `Uninit`.
#[inline(always)]
Expand Down
2 changes: 1 addition & 1 deletion compiler/rustc_infer/src/infer/outlives/for_liveness.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ where
//
// We search through the item bounds and where clauses for
// either `'static` or a unique outlives region, and if one is
// found, we just need to prove that that region is still live.
// found, we just need to prove that region is still live.
// If one is not found, then we continue to walk through the alias.
ty::Alias(kind, ty::AliasTy { def_id, args, .. }) => {
let tcx = self.tcx;
Expand Down
2 changes: 1 addition & 1 deletion compiler/rustc_resolve/src/late.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4303,7 +4303,7 @@ impl<'a: 'ast, 'b, 'ast, 'tcx> LateResolutionVisitor<'a, 'b, 'ast, 'tcx> {
// Make sure `A::B` in `<T as A>::B::C` is a trait item.
//
// Currently, `path` names the full item (`A::B::C`, in
// our example). so we extract the prefix of that that is
// our example). so we extract the prefix of that is
// the trait (the slice upto and including
// `qself.position`). And then we recursively resolve that,
// but with `qself` set to `None`.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ impl<'cx, 'tcx> SelectionContext<'cx, 'tcx> {

// Given a transmutation from `&'a (mut) Src` and `&'dst (mut) Dst`,
// it is always the case that `Src` must be transmutable into `Dst`,
// and that that `'src` must outlive `'dst`.
// and that `'src` must outlive `'dst`.
let mut obls = vec![make_transmute_obl(src_ty, dst_ty)];
if !assume.lifetimes {
obls.push(make_outlives_obl(src_lifetime, dst_lifetime));
Expand Down
2 changes: 1 addition & 1 deletion library/core/src/mem/transmutability.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ where
#[derive(PartialEq, Eq, Clone, Copy, Debug)]
pub struct Assume {
/// When `false`, [`TransmuteFrom`] is not implemented for transmutations
/// that might violate the the alignment requirements of references; e.g.:
/// that might violate the alignment requirements of references; e.g.:
///
#[cfg_attr(bootstrap, doc = "```rust,ignore not runnable on bootstrap")]
#[cfg_attr(not(bootstrap), doc = "```compile_fail,E0277")]
Expand Down
2 changes: 1 addition & 1 deletion library/core/src/pin.rs
Original file line number Diff line number Diff line change
Expand Up @@ -733,7 +733,7 @@
//! sensitivity, it will need to be structurally pinned.
//!
//! A useful test is if [`unsafe`] code that consumes <code>[Pin]\<[&mut Struct][&mut]></code>
//! also needs to take note of the address of the field itself, it may be evidence that that field
//! also needs to take note of the address of the field itself, it may be evidence that field
//! is structurally pinned. Unfortunately, there are no hard-and-fast rules.
//!
//! ### Choosing pinning *not to be* structural for `field`...
Expand Down
2 changes: 1 addition & 1 deletion library/std/src/sync/reentrant_lock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ cfg_if!(
// match do we read out the actual TID.
// Note also that we can use relaxed atomic operations here, because
// we only ever read from the tid if `tls_addr` matches the current
// TLS address. In that case, either the the tid has been set by
// TLS address. In that case, either the tid has been set by
// the current thread, or by a thread that has terminated before
// the current thread was created. In either case, no further
// synchronization is needed (as per <https://github.com/rust-lang/miri/issues/3450>)
Expand Down
2 changes: 1 addition & 1 deletion tests/incremental/hashes/enum_constructors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ pub fn change_field_order_struct_like() -> Enum {
#[rustc_clean(cfg="cfail3")]
#[rustc_clean(cfg="cfail5", except="opt_hir_owner_nodes,typeck,optimized_mir")]
#[rustc_clean(cfg="cfail6")]
// FIXME(michaelwoerister):Interesting. I would have thought that that changes the MIR. And it
// FIXME(michaelwoerister):Interesting. I would have thought that changes the MIR. And it
// would if it were not all constants
pub fn change_field_order_struct_like() -> Enum {
Enum::Struct {
Expand Down
2 changes: 1 addition & 1 deletion tests/mir-opt/copy-prop/dead_stores_better.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// skip-filecheck
// EMIT_MIR_FOR_EACH_PANIC_STRATEGY
// This is a copy of the `dead_stores_79191` test, except that we turn on DSE. This demonstrates
// that that pass enables this one to do more optimizations.
// that pass enables this one to do more optimizations.

//@ test-mir-pass: CopyProp
//@ compile-flags: -Zmir-enable-passes=+DeadStoreElimination
Expand Down
2 changes: 1 addition & 1 deletion tests/mir-opt/dest-prop/dead_stores_better.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// EMIT_MIR_FOR_EACH_PANIC_STRATEGY
// This is a copy of the `dead_stores_79191` test, except that we turn on DSE. This demonstrates
// that that pass enables this one to do more optimizations.
// that pass enables this one to do more optimizations.

//@ test-mir-pass: DestinationPropagation
//@ compile-flags: -Zmir-enable-passes=+DeadStoreElimination
Expand Down
2 changes: 1 addition & 1 deletion tests/run-make/remap-path-prefix-dwarf/rmake.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ fn main() {
dwarf_test: DwarfDump::AvoidSrcPath,
});
// The compiler is called with a *RELATIVE PATH* as input. We are remapping a *SUB-DIRECTORY*
// of the compiler's working directory. This test makes sure that that directory is remapped
// of the compiler's working directory. This test makes sure that directory is remapped
// even though it won't actually show up in this form in the compiler's SourceMap and instead
// is only constructed on demand during debuginfo generation.
check_dwarf(DwarfTest {
Expand Down

0 comments on commit 8f84aca

Please sign in to comment.