Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit edefa41

Browse files
committed
Auto merge of rust-lang#106998 - matthiaskrgr:rollup-hmfisji, r=matthiaskrgr
Rollup of 7 pull requests Successful merges: - rust-lang#104505 (Remove double spaces after dots in comments) - rust-lang#106784 (prevent E0512 from emitting [type error] by checking the references_error) - rust-lang#106834 (new trait solver: only consider goal changed if response is not identity) - rust-lang#106889 (Mention the lack of `windows_mut` in `windows`) - rust-lang#106963 (Use `scope_expr_id` from `ProbeCtxt`) - rust-lang#106970 (Switch to `EarlyBinder` for `item_bounds` query) - rust-lang#106980 (Hide `_use_mk_alias_ty_instead` in `<AliasTy as Debug>::fmt`) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2 parents 3984bc5 + 48bd3ab commit edefa41

File tree

173 files changed

+412
-366
lines changed

Some content is hidden

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

173 files changed

+412
-366
lines changed

compiler/rustc_abi/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1263,8 +1263,8 @@ pub enum Variants<V: Idx> {
12631263

12641264
/// Enum-likes with more than one inhabited variant: each variant comes with
12651265
/// a *discriminant* (usually the same as the variant index but the user can
1266-
/// assign explicit discriminant values). That discriminant is encoded
1267-
/// as a *tag* on the machine. The layout of each variant is
1266+
/// assign explicit discriminant values). That discriminant is encoded
1267+
/// as a *tag* on the machine. The layout of each variant is
12681268
/// a struct, and they all have space reserved for the tag.
12691269
/// For enums, the tag is the sole field of the layout.
12701270
Multiple {

compiler/rustc_ast/src/util/parser.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,7 @@ impl ExprPrecedence {
304304
| ExprPrecedence::Yeet => PREC_JUMP,
305305

306306
// `Range` claims to have higher precedence than `Assign`, but `x .. x = x` fails to
307-
// parse, instead of parsing as `(x .. x) = x`. Giving `Range` a lower precedence
307+
// parse, instead of parsing as `(x .. x) = x`. Giving `Range` a lower precedence
308308
// ensures that `pprust` will add parentheses in the right places to get the desired
309309
// parse.
310310
ExprPrecedence::Range => PREC_RANGE,

compiler/rustc_ast_lowering/src/index.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ pub(super) fn index_hir<'hir>(
3838
) -> (IndexVec<ItemLocalId, Option<ParentedNode<'hir>>>, FxHashMap<LocalDefId, ItemLocalId>) {
3939
let mut nodes = IndexVec::new();
4040
// This node's parent should never be accessed: the owner's parent is computed by the
41-
// hir_owner_parent query. Make it invalid (= ItemLocalId::MAX) to force an ICE whenever it is
41+
// hir_owner_parent query. Make it invalid (= ItemLocalId::MAX) to force an ICE whenever it is
4242
// used.
4343
nodes.push(Some(ParentedNode { parent: ItemLocalId::INVALID, node: item.into() }));
4444
let mut collector = NodeCollector {

compiler/rustc_ast_lowering/src/item.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -523,7 +523,7 @@ impl<'hir> LoweringContext<'_, 'hir> {
523523
//
524524
// The first two are produced by recursively invoking
525525
// `lower_use_tree` (and indeed there may be things
526-
// like `use foo::{a::{b, c}}` and so forth). They
526+
// like `use foo::{a::{b, c}}` and so forth). They
527527
// wind up being directly added to
528528
// `self.items`. However, the structure of this
529529
// function also requires us to return one item, and

compiler/rustc_ast_lowering/src/lib.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -662,7 +662,7 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
662662
self.arena.alloc(hir::OwnerInfo { nodes, parenting, attrs, trait_map })
663663
}
664664

665-
/// Hash the HIR node twice, one deep and one shallow hash. This allows to differentiate
665+
/// Hash the HIR node twice, one deep and one shallow hash. This allows to differentiate
666666
/// queries which depend on the full HIR tree and those which only depend on the item signature.
667667
fn hash_owner(
668668
&mut self,
@@ -1193,7 +1193,7 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
11931193
itctx: &ImplTraitContext,
11941194
) -> hir::Ty<'hir> {
11951195
// Check whether we should interpret this as a bare trait object.
1196-
// This check mirrors the one in late resolution. We only introduce this special case in
1196+
// This check mirrors the one in late resolution. We only introduce this special case in
11971197
// the rare occurrence we need to lower `Fresh` anonymous lifetimes.
11981198
// The other cases when a qpath should be opportunistically made a trait object are handled
11991199
// by `ty_path`.
@@ -1918,7 +1918,7 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
19181918
this.with_remapping(new_remapping, |this| {
19191919
// We have to be careful to get elision right here. The
19201920
// idea is that we create a lifetime parameter for each
1921-
// lifetime in the return type. So, given a return type
1921+
// lifetime in the return type. So, given a return type
19221922
// like `async fn foo(..) -> &[&u32]`, we lower to `impl
19231923
// Future<Output = &'1 [ &'2 u32 ]>`.
19241924
//
@@ -2012,7 +2012,7 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
20122012

20132013
// Create the `Foo<...>` reference itself. Note that the `type
20142014
// Foo = impl Trait` is, internally, created as a child of the
2015-
// async fn, so the *type parameters* are inherited. It's
2015+
// async fn, so the *type parameters* are inherited. It's
20162016
// only the lifetime parameters that we must supply.
20172017
let opaque_ty_ref = hir::TyKind::OpaqueDef(
20182018
hir::ItemId { owner_id: hir::OwnerId { def_id: opaque_ty_def_id } },

compiler/rustc_ast_pretty/src/pprust/state/expr.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -473,10 +473,10 @@ impl<'a> State<'a> {
473473
self.word("]");
474474
}
475475
ast::ExprKind::Range(start, end, limits) => {
476-
// Special case for `Range`. `AssocOp` claims that `Range` has higher precedence
476+
// Special case for `Range`. `AssocOp` claims that `Range` has higher precedence
477477
// than `Assign`, but `x .. x = x` gives a parse error instead of `x .. (x = x)`.
478478
// Here we use a fake precedence value so that any child with lower precedence than
479-
// a "normal" binop gets parenthesized. (`LOr` is the lowest-precedence binop.)
479+
// a "normal" binop gets parenthesized. (`LOr` is the lowest-precedence binop.)
480480
let fake_prec = AssocOp::LOr.precedence() as i8;
481481
if let Some(e) = start {
482482
self.print_expr_maybe_paren(e, fake_prec);

compiler/rustc_borrowck/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2173,7 +2173,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
21732173
// `self.foo` -- we want to double
21742174
// check that the location `*self`
21752175
// is mutable (i.e., this is not a
2176-
// `Fn` closure). But if that
2176+
// `Fn` closure). But if that
21772177
// check succeeds, we want to
21782178
// *blame* the mutability on
21792179
// `place` (that is,

compiler/rustc_borrowck/src/member_constraints.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ where
109109
R1: Copy + Hash + Eq,
110110
{
111111
/// Remap the "member region" key using `map_fn`, producing a new
112-
/// member constraint set. This is used in the NLL code to map from
112+
/// member constraint set. This is used in the NLL code to map from
113113
/// the original `RegionVid` to an scc index. In some cases, we
114114
/// may have multiple `R1` values mapping to the same `R2` key -- that
115115
/// is ok, the two sets will be merged.
@@ -158,7 +158,7 @@ where
158158
}
159159

160160
/// Iterate down the constraint indices associated with a given
161-
/// peek-region. You can then use `choice_regions` and other
161+
/// peek-region. You can then use `choice_regions` and other
162162
/// methods to access data.
163163
pub(crate) fn indices(
164164
&self,

compiler/rustc_borrowck/src/nll.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ pub(super) fn dump_annotation<'tcx>(
385385

386386
// When the enclosing function is tagged with `#[rustc_regions]`,
387387
// we dump out various bits of state as warnings. This is useful
388-
// for verifying that the compiler is behaving as expected. These
388+
// for verifying that the compiler is behaving as expected. These
389389
// warnings focus on the closure region requirements -- for
390390
// viewing the intraprocedural state, the -Zdump-mir output is
391391
// better.

compiler/rustc_borrowck/src/place_ext.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ impl<'tcx> PlaceExt<'tcx> for Place<'tcx> {
6363
ty::RawPtr(..) | ty::Ref(_, _, hir::Mutability::Not) => {
6464
// For both derefs of raw pointers and `&T`
6565
// references, the original path is `Copy` and
66-
// therefore not significant. In particular,
66+
// therefore not significant. In particular,
6767
// there is nothing the user can do to the
6868
// original path that would invalidate the
6969
// newly created reference -- and if there

0 commit comments

Comments
 (0)