Skip to content

Commit c0b05aa

Browse files
authored
Merge pull request #4660 from rust-lang/rustup-2025-11-03
Automatic Rustup
2 parents 119f642 + a88edb7 commit c0b05aa

File tree

1,191 files changed

+19457
-9227
lines changed

Some content is hidden

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

1,191 files changed

+19457
-9227
lines changed

.github/ISSUE_TEMPLATE/tracking_issue.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ for larger features an implementation could be broken up into multiple PRs.
5050
[stabilization-guide]: https://rustc-dev-guide.rust-lang.org/stabilization_guide.html#stabilization-pr
5151
[doc-guide]: https://rustc-dev-guide.rust-lang.org/stabilization_guide.html#documentation-prs
5252
[nightly-style-procedure]: https://github.com/rust-lang/style-team/blob/main/nightly-style-procedure.md
53-
[Style Guide]: https://github.com/rust-lang/rust/tree/master/src/doc/style-guide
53+
[Style Guide]: https://github.com/rust-lang/rust/tree/HEAD/src/doc/style-guide
5454

5555
### Unresolved Questions
5656
<!--

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,7 @@ jobs:
323323
# If a some dependent job has failed, this exits with 1.
324324
- name: calculate the correct exit status
325325
run: jq --exit-status 'all(.result == "success" or .result == "skipped")' <<< '${{ toJson(needs) }}'
326-
# Publish the toolstate if an auto build succeeds (just before push to master)
326+
# Publish the toolstate if an auto build succeeds (just before push to the default branch)
327327
- name: publish toolstate
328328
run: src/ci/publish_toolstate.sh
329329
shell: bash

.github/workflows/post-merge.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Workflow that runs after a merge to master, analyses changes in test executions
1+
# Workflow that runs after a merge to the default branch, analyses changes in test executions
22
# and posts the result to the merged PR.
33

44
name: Post merge analysis

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,10 @@ node_modules
9090
## Rustdoc GUI tests
9191
tests/rustdoc-gui/src/**.lock
9292

93+
## Test dashboard
94+
.citool-cache/
95+
test-dashboard/
96+
9397
## direnv
9498
/.envrc
9599
/.direnv/

Cargo.lock

Lines changed: 16 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -474,11 +474,10 @@ version = "0.1.0"
474474

475475
[[package]]
476476
name = "cc"
477-
version = "1.2.39"
477+
version = "1.2.16"
478478
source = "registry+https://github.com/rust-lang/crates.io-index"
479-
checksum = "e1354349954c6fc9cb0deab020f27f783cf0b604e8bb754dc4658ecf0d29c35f"
479+
checksum = "be714c154be609ec7f5dad223a33bf1482fff90472de28f7362806e6d4832b8c"
480480
dependencies = [
481-
"find-msvc-tools",
482481
"jobserver",
483482
"libc",
484483
"shlex",
@@ -581,7 +580,7 @@ checksum = "b94f61472cee1439c0b966b47e3aca9ae07e45d070759512cd390ea2bebc6675"
581580

582581
[[package]]
583582
name = "clippy"
584-
version = "0.1.92"
583+
version = "0.1.93"
585584
dependencies = [
586585
"anstream",
587586
"askama",
@@ -608,7 +607,7 @@ dependencies = [
608607

609608
[[package]]
610609
name = "clippy_config"
611-
version = "0.1.92"
610+
version = "0.1.93"
612611
dependencies = [
613612
"clippy_utils",
614613
"itertools",
@@ -631,7 +630,7 @@ dependencies = [
631630

632631
[[package]]
633632
name = "clippy_lints"
634-
version = "0.1.92"
633+
version = "0.1.93"
635634
dependencies = [
636635
"arrayvec",
637636
"cargo_metadata 0.18.1",
@@ -663,7 +662,7 @@ dependencies = [
663662

664663
[[package]]
665664
name = "clippy_utils"
666-
version = "0.1.92"
665+
version = "0.1.93"
667666
dependencies = [
668667
"arrayvec",
669668
"itertools",
@@ -1067,7 +1066,7 @@ dependencies = [
10671066

10681067
[[package]]
10691068
name = "declare_clippy_lint"
1070-
version = "0.1.92"
1069+
version = "0.1.93"
10711070

10721071
[[package]]
10731072
name = "derive-where"
@@ -1289,7 +1288,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
12891288
checksum = "778e2ac28f6c47af28e4907f13ffd1e1ddbd400980a9abd7c8df189bf578a5ad"
12901289
dependencies = [
12911290
"libc",
1292-
"windows-sys 0.60.2",
1291+
"windows-sys 0.52.0",
12931292
]
12941293

12951294
[[package]]
@@ -2102,9 +2101,9 @@ checksum = "9fa0e2a1fcbe2f6be6c42e342259976206b383122fc152e872795338b5a3f3a7"
21022101

21032102
[[package]]
21042103
name = "libc"
2105-
version = "0.2.174"
2104+
version = "0.2.177"
21062105
source = "registry+https://github.com/rust-lang/crates.io-index"
2107-
checksum = "1171693293099992e19cddea4e8b849964e9846f4acee11b3948bcc337be8776"
2106+
checksum = "2874a2af47a2325c2001a6e6fad9b16a53b802102b528163885171cf92b15976"
21082107

21092108
[[package]]
21102109
name = "libdbus-sys"
@@ -2155,7 +2154,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
21552154
checksum = "07033963ba89ebaf1584d767badaa2e8fcec21aedea6b8c0346d487d49c28667"
21562155
dependencies = [
21572156
"cfg-if",
2158-
"windows-targets 0.53.3",
2157+
"windows-targets 0.52.6",
21592158
]
21602159

21612160
[[package]]
@@ -2217,9 +2216,9 @@ dependencies = [
22172216

22182217
[[package]]
22192218
name = "linux-raw-sys"
2220-
version = "0.9.4"
2219+
version = "0.11.0"
22212220
source = "registry+https://github.com/rust-lang/crates.io-index"
2222-
checksum = "cd945864f07fe9f5371a27ad7b52a172b4b499999f1d97574c9fa68373937e12"
2221+
checksum = "df1d3c3b53da64cf5760482273a98e575c651a67eec7f77df96b5b642de8f039"
22232222

22242223
[[package]]
22252224
name = "litemap"
@@ -4898,15 +4897,15 @@ dependencies = [
48984897

48994898
[[package]]
49004899
name = "rustix"
4901-
version = "1.0.8"
4900+
version = "1.1.2"
49024901
source = "registry+https://github.com/rust-lang/crates.io-index"
4903-
checksum = "11181fbabf243db407ef8df94a6ce0b2f9a733bd8be4ad02b4eda9602296cac8"
4902+
checksum = "cd15f8a2c5551a84d56efdc1cd049089e409ac19a3072d5037a17fd70719ff3e"
49044903
dependencies = [
49054904
"bitflags",
49064905
"errno",
49074906
"libc",
49084907
"linux-raw-sys",
4909-
"windows-sys 0.60.2",
4908+
"windows-sys 0.52.0",
49104909
]
49114910

49124911
[[package]]

compiler/rustc_ast/src/ast.rs

Lines changed: 36 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -789,14 +789,14 @@ pub struct PatField {
789789
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
790790
#[derive(Encodable, Decodable, HashStable_Generic, Walkable)]
791791
pub enum ByRef {
792-
Yes(Mutability),
792+
Yes(Pinnedness, Mutability),
793793
No,
794794
}
795795

796796
impl ByRef {
797797
#[must_use]
798798
pub fn cap_ref_mutability(mut self, mutbl: Mutability) -> Self {
799-
if let ByRef::Yes(old_mutbl) = &mut self {
799+
if let ByRef::Yes(_, old_mutbl) = &mut self {
800800
*old_mutbl = cmp::min(*old_mutbl, mutbl);
801801
}
802802
self
@@ -814,20 +814,33 @@ pub struct BindingMode(pub ByRef, pub Mutability);
814814

815815
impl BindingMode {
816816
pub const NONE: Self = Self(ByRef::No, Mutability::Not);
817-
pub const REF: Self = Self(ByRef::Yes(Mutability::Not), Mutability::Not);
817+
pub const REF: Self = Self(ByRef::Yes(Pinnedness::Not, Mutability::Not), Mutability::Not);
818+
pub const REF_PIN: Self =
819+
Self(ByRef::Yes(Pinnedness::Pinned, Mutability::Not), Mutability::Not);
818820
pub const MUT: Self = Self(ByRef::No, Mutability::Mut);
819-
pub const REF_MUT: Self = Self(ByRef::Yes(Mutability::Mut), Mutability::Not);
820-
pub const MUT_REF: Self = Self(ByRef::Yes(Mutability::Not), Mutability::Mut);
821-
pub const MUT_REF_MUT: Self = Self(ByRef::Yes(Mutability::Mut), Mutability::Mut);
821+
pub const REF_MUT: Self = Self(ByRef::Yes(Pinnedness::Not, Mutability::Mut), Mutability::Not);
822+
pub const REF_PIN_MUT: Self =
823+
Self(ByRef::Yes(Pinnedness::Pinned, Mutability::Mut), Mutability::Not);
824+
pub const MUT_REF: Self = Self(ByRef::Yes(Pinnedness::Not, Mutability::Not), Mutability::Mut);
825+
pub const MUT_REF_PIN: Self =
826+
Self(ByRef::Yes(Pinnedness::Pinned, Mutability::Not), Mutability::Mut);
827+
pub const MUT_REF_MUT: Self =
828+
Self(ByRef::Yes(Pinnedness::Not, Mutability::Mut), Mutability::Mut);
829+
pub const MUT_REF_PIN_MUT: Self =
830+
Self(ByRef::Yes(Pinnedness::Pinned, Mutability::Mut), Mutability::Mut);
822831

823832
pub fn prefix_str(self) -> &'static str {
824833
match self {
825834
Self::NONE => "",
826835
Self::REF => "ref ",
836+
Self::REF_PIN => "ref pin const ",
827837
Self::MUT => "mut ",
828838
Self::REF_MUT => "ref mut ",
839+
Self::REF_PIN_MUT => "ref pin mut ",
829840
Self::MUT_REF => "mut ref ",
841+
Self::MUT_REF_PIN => "mut ref pin ",
830842
Self::MUT_REF_MUT => "mut ref mut ",
843+
Self::MUT_REF_PIN_MUT => "mut ref pin mut ",
831844
}
832845
}
833846
}
@@ -3540,8 +3553,9 @@ impl Item {
35403553
ItemKind::Const(i) => Some(&i.generics),
35413554
ItemKind::Fn(i) => Some(&i.generics),
35423555
ItemKind::TyAlias(i) => Some(&i.generics),
3543-
ItemKind::TraitAlias(_, generics, _)
3544-
| ItemKind::Enum(_, generics, _)
3556+
ItemKind::TraitAlias(i) => Some(&i.generics),
3557+
3558+
ItemKind::Enum(_, generics, _)
35453559
| ItemKind::Struct(_, generics, _)
35463560
| ItemKind::Union(_, generics, _) => Some(&generics),
35473561
ItemKind::Trait(i) => Some(&i.generics),
@@ -3623,6 +3637,15 @@ impl Default for FnHeader {
36233637
}
36243638
}
36253639

3640+
#[derive(Clone, Encodable, Decodable, Debug, Walkable)]
3641+
pub struct TraitAlias {
3642+
pub constness: Const,
3643+
pub ident: Ident,
3644+
pub generics: Generics,
3645+
#[visitable(extra = BoundKind::Bound)]
3646+
pub bounds: GenericBounds,
3647+
}
3648+
36263649
#[derive(Clone, Encodable, Decodable, Debug, Walkable)]
36273650
pub struct Trait {
36283651
pub constness: Const,
@@ -3798,7 +3821,7 @@ pub enum ItemKind {
37983821
/// Trait alias.
37993822
///
38003823
/// E.g., `trait Foo = Bar + Quux;`.
3801-
TraitAlias(Ident, Generics, GenericBounds),
3824+
TraitAlias(Box<TraitAlias>),
38023825
/// An implementation.
38033826
///
38043827
/// E.g., `impl<A> Foo<A> { .. }` or `impl<A> Trait for Foo<A> { .. }`.
@@ -3831,7 +3854,7 @@ impl ItemKind {
38313854
| ItemKind::Struct(ident, ..)
38323855
| ItemKind::Union(ident, ..)
38333856
| ItemKind::Trait(box Trait { ident, .. })
3834-
| ItemKind::TraitAlias(ident, ..)
3857+
| ItemKind::TraitAlias(box TraitAlias { ident, .. })
38353858
| ItemKind::MacroDef(ident, _)
38363859
| ItemKind::Delegation(box Delegation { ident, .. }) => Some(ident),
38373860

@@ -3888,7 +3911,7 @@ impl ItemKind {
38883911
| Self::Struct(_, generics, _)
38893912
| Self::Union(_, generics, _)
38903913
| Self::Trait(box Trait { generics, .. })
3891-
| Self::TraitAlias(_, generics, _)
3914+
| Self::TraitAlias(box TraitAlias { generics, .. })
38923915
| Self::Impl(Impl { generics, .. }) => Some(generics),
38933916
_ => None,
38943917
}
@@ -4050,8 +4073,8 @@ mod size_asserts {
40504073
static_assert_size!(GenericBound, 88);
40514074
static_assert_size!(Generics, 40);
40524075
static_assert_size!(Impl, 64);
4053-
static_assert_size!(Item, 144);
4054-
static_assert_size!(ItemKind, 80);
4076+
static_assert_size!(Item, 136);
4077+
static_assert_size!(ItemKind, 72);
40554078
static_assert_size!(LitKind, 24);
40564079
static_assert_size!(Local, 96);
40574080
static_assert_size!(MetaItemLit, 40);

compiler/rustc_ast/src/visit.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -368,6 +368,7 @@ macro_rules! common_visitor_and_walkers {
368368
crate::tokenstream::TokenStream,
369369
Movability,
370370
Mutability,
371+
Pinnedness,
371372
Result<(), rustc_span::ErrorGuaranteed>,
372373
rustc_data_structures::fx::FxHashMap<Symbol, usize>,
373374
rustc_span::ErrorGuaranteed,
@@ -833,8 +834,8 @@ macro_rules! common_visitor_and_walkers {
833834
visit_visitable!($($mut)? vis, impl_),
834835
ItemKind::Trait(trait_) =>
835836
visit_visitable!($($mut)? vis, trait_),
836-
ItemKind::TraitAlias(ident, generics, bounds) => {
837-
visit_visitable!($($mut)? vis, ident, generics);
837+
ItemKind::TraitAlias(box TraitAlias { constness, ident, generics, bounds}) => {
838+
visit_visitable!($($mut)? vis, constness, ident, generics);
838839
visit_visitable_with!($($mut)? vis, bounds, BoundKind::Bound)
839840
}
840841
ItemKind::MacCall(m) =>

compiler/rustc_ast_ir/src/lib.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -311,3 +311,10 @@ pub enum Pinnedness {
311311
Not,
312312
Pinned,
313313
}
314+
315+
impl Pinnedness {
316+
/// Return `true` if self is pinned
317+
pub fn is_pinned(self) -> bool {
318+
matches!(self, Self::Pinned)
319+
}
320+
}

compiler/rustc_ast_lowering/src/contract.rs

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
use std::sync::Arc;
2+
13
use thin_vec::thin_vec;
24

35
use crate::LoweringContext;
@@ -128,7 +130,7 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
128130
let req_span = self.mark_span_with_reason(
129131
rustc_span::DesugaringKind::Contract,
130132
lowered_req.span,
131-
None,
133+
Some(Arc::clone(&self.allow_contracts)),
132134
);
133135
let precond = self.expr_call_lang_item_fn_mut(
134136
req_span,
@@ -143,8 +145,11 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
143145
ens: &Box<rustc_ast::Expr>,
144146
) -> &'hir rustc_hir::Expr<'hir> {
145147
let ens_span = self.lower_span(ens.span);
146-
let ens_span =
147-
self.mark_span_with_reason(rustc_span::DesugaringKind::Contract, ens_span, None);
148+
let ens_span = self.mark_span_with_reason(
149+
rustc_span::DesugaringKind::Contract,
150+
ens_span,
151+
Some(Arc::clone(&self.allow_contracts)),
152+
);
148153
let lowered_ens = self.lower_expr_mut(&ens);
149154
self.expr_call_lang_item_fn(
150155
ens_span,

0 commit comments

Comments
 (0)