35634 Commits

Author SHA1 Message Date
Jakub Beránek
ca679a2f94
Add CI workflow for periodically performing josh pulls 2025-07-22 18:15:54 +02:00
Jakub Beránek
00a47e3299
Apply suggestions from code review
Co-authored-by: Laurențiu Nicola <lnicola@users.noreply.github.com>
2025-07-22 18:14:20 +02:00
bors
8c24528bb8 Auto merge of #144222 - Kobzol:stdarch-push, r=folkertdev
stdarch subtree update

Subtree update of `stdarch` to 5531955678.

Created using https://github.com/rust-lang/josh-sync.

I saw that there were non-trivial changes made to `std_detect` in `stdarch` recently. So I want to get them merged here before we move forward with https://github.com/rust-lang/rust/pull/143412.

r? `@folkertdev`
2025-07-22 15:25:31 +00:00
Jakub Beránek
9c1750d0b5
Document synces using josh-sync 2025-07-22 15:25:18 +02:00
Jakub Beránek
ceaa0376ef
Remove pull/push functionality from xtask 2025-07-22 15:25:16 +02:00
Chayim Refael Friedman
c7ceb39f67 Parse for<'a> [const]
And also refactor parsing of HRTB.
2025-07-22 16:24:42 +03:00
Laurențiu Nicola
a54351effd
Merge pull request #20279 from lnicola/add-josh-sync
internal: Add `josh-sync.toml`
2025-07-22 13:08:09 +00:00
Laurențiu Nicola
091ba7fd32 Add josh-sync.toml 2025-07-22 15:56:41 +03:00
Shoyu Vanilla (Flint)
578a523686
Merge pull request #20277 from rust-lang/dependabot/npm_and_yarn/editors/code/form-data-4.0.4
Bump form-data from 4.0.2 to 4.0.4 in /editors/code
2025-07-22 11:11:53 +00:00
Florian Diebold
6e4e0883b0
Merge pull request #20278 from lnicola/analysis-stats-mir-lowering-only
internal: Support filtering in analysis-stats MIR lowering
2025-07-22 08:35:41 +00:00
bors
9b11f5a0ce Auto merge of #144205 - hkBst:flt2dec, r=workingjubilee
flt2dec: replace for loop by iter_mut

Perf is explored in https://github.com/rust-lang/rust/issues/144118, which initially showed small losses, but then also showed significant gains. Both are real, but given the smallness of the losses, this seems a good change.
2025-07-22 08:28:29 +00:00
Laurențiu Nicola
c9b07766b7 Support filtering in analysis-stats MIR lowering 2025-07-22 11:22:16 +03:00
dependabot[bot]
36e31f9142
Bump form-data from 4.0.2 to 4.0.4 in /editors/code
Bumps [form-data](https://github.com/form-data/form-data) from 4.0.2 to 4.0.4.
- [Release notes](https://github.com/form-data/form-data/releases)
- [Changelog](https://github.com/form-data/form-data/blob/master/CHANGELOG.md)
- [Commits](https://github.com/form-data/form-data/compare/v4.0.2...v4.0.4)

---
updated-dependencies:
- dependency-name: form-data
  dependency-version: 4.0.4
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-07-22 05:30:29 +00:00
Shoyu Vanilla (Flint)
bdfc7709bf
Merge pull request #20269 from Hmikihiro/migrate_indent_mapping
Migrate AstNodeEdit::Indent to SyntaxEditor
2025-07-22 04:07:47 +00:00
Shoyu Vanilla (Flint)
7cbc5a3d57
Merge pull request #20270 from Hmikihiro/migrate_generate_new
Migrate `generate new` assist to use `SyntaxEditor`
2025-07-22 03:41:03 +00:00
bors
daa33520f2 Auto merge of #144269 - jieyouxu:rollup-137ysl2, r=jieyouxu
Rollup of 14 pull requests

Successful merges:

 - rust-lang/rust#142097 (gpu offload host code generation)
 - rust-lang/rust#143430 (Lower extra lifetimes before normal generic params.)
 - rust-lang/rust#143768 (Constify Try, From, TryFrom and relevant traits)
 - rust-lang/rust#143816 (Implement `check` for compiletest and RA using tool macro)
 - rust-lang/rust#143985 (rustc_public: de-StableMIR-ize)
 - rust-lang/rust#144027 (clippy: make tests work in stage 1)
 - rust-lang/rust#144080 (Mitigate `#[align]` name resolution ambiguity regression with a rename)
 - rust-lang/rust#144176 (Add approval blocking labels for new bors)
 - rust-lang/rust#144187 (fix handling of base address for TypeId allocations)
 - rust-lang/rust#144212 (Remove the ptr_unique lang item)
 - rust-lang/rust#144243 (Subtree update of `rust-analyzer`)
 - rust-lang/rust#144246 (Don't use another main test file as auxiliary)
 - rust-lang/rust#144251 (rustc-dev-guide subtree update)
 - rust-lang/rust#144254 (opt-dist: make `artifact-dir` an absolute path for `opt-dist local`)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-07-21 19:48:22 +00:00
许杰友 Jieyou Xu (Joe)
05737ad03a
Rollup merge of #144254 - ognevny:opt-dist-artifact-dir, r=Kobzol
opt-dist: make `artifact-dir` an absolute path for `opt-dist local`

...like for CI environments. the same logic applied as for `build_dir`. fixes the issue where some intermediate steps fail due to path being relative to an active directory

r? Kobzol

try-job: dist-x86_64-msvc
try-job: dist-x86_64-linux
2025-07-22 00:54:33 +08:00
许杰友 Jieyou Xu (Joe)
3290c665ff
Rollup merge of #144251 - tshepang:rdg-sync, r=jieyouxu
rustc-dev-guide subtree update

Subtree update of `rustc-dev-guide` to cca233729f.

Created using https://github.com/rust-lang/josh-sync.

r? ```@ghost```
2025-07-22 00:54:32 +08:00
许杰友 Jieyou Xu (Joe)
3a9ffd37ee
Rollup merge of #144246 - jieyouxu:no-dual-test, r=lqd,RalfJung
Don't use another main test file as auxiliary

In this case, the exact extern crate isn't very important, it just needs to not be another main test file.

This is part of the changes needed to address the spurious failures from a main test `../removing-extern-crate.rs` being both an auxiliary and a main test file, causing fs races due to multiple `rustc` processes in multiple test threads trying to build the main test file both as a main test and also as an auxiliary at around the same time.

Part 1 of rust-lang/rust#144237.

r? ``@RalfJung`` (or compiler)
2025-07-22 00:54:32 +08:00
许杰友 Jieyou Xu (Joe)
1bcd093474
Rollup merge of #144243 - lnicola:sync-from-ra, r=lnicola
Subtree update of `rust-analyzer`

r? ```@ghost```
2025-07-22 00:54:31 +08:00
许杰友 Jieyou Xu (Joe)
181c0956d9
Rollup merge of #144027 - RalfJung:clippy, r=Mark-Simulacrum
clippy: make tests work in stage 1

This finally fixes https://github.com/rust-lang/rust/issues/78717 :)

Similar to what Miri already does, the clippy test step needs to carefully consider  which compiler is used to build clippy and which compiler is linked into clippy (and thus must be used to build the test dependencies). On top of that we have some extra complications that Miri avoided by using `cargo-miri` for building its test dependencies: we need cargo to use the right rustc and the right sysroot, but https://github.com/rust-lang/cargo/issues/4423 makes this quite hard to do. See the long comment in `src/tools/clippy/tests/compile-test.rs` for details.

Some clippy tests tried to import rustc crates; that fundamentally requires a full bootstrap loop so it cannot work in stage 1. I had to kind of guess what those tests were doing so I don't know if my changes there make any sense.

Cc ```@flip1995``` ```@Kobzol```
2025-07-22 00:54:28 +08:00
Chayim Refael Friedman
9a1ee18e4d
Merge pull request #20273 from ShoyuVanilla/match-adjusts
fix: Apply adjusts to pats and exprs when doing pat analysis
2025-07-21 16:31:09 +00:00
Shoyu Vanilla
e587367b4d fix: Apply adjusts to pats and exprs when doing pat analysis 2025-07-22 01:18:48 +09:00
Laurențiu Nicola
0d4f56de04
Merge pull request #20272 from glaubitz/x32-fixes
hir-def: Don't apply x86_64-specific asserts on x32
2025-07-21 15:18:46 +00:00
John Paul Adrian Glaubitz
25122d9289 hir-def: Don't apply x86_64-specific asserts on x32
This fixes the rustc build on x32 for which struct sizes differ.
2025-07-21 17:03:07 +02:00
Shoyu Vanilla (Flint)
4c7a8cbe8d
Merge pull request #20271 from ChayimFriedman2/cfg-settest-flycheck
fix: Disable tests in flycheck if `cfg.setTest` is set to false
2025-07-21 14:27:12 +00:00
Chayim Refael Friedman
2e0b3643ed Disable tests in flycheck if cfg.setTest is set to false 2025-07-21 16:34:12 +03:00
Tshepang Mbambo
cb08d77bf9
Merge pull request #2512 from rust-lang/rustc-pull
Rustc pull update
2025-07-21 11:16:20 +02:00
Hayashi Mikihiro
9cc03e01c5 migrate generate new 2025-07-21 17:22:03 +09:00
Laurențiu Nicola
8b45a73551
Merge pull request #20268 from lnicola/sync-from-rust
minor: Sync from downstream
2025-07-21 06:58:10 +00:00
Laurențiu Nicola
e0e4e26474 Downgrade ra-ap-rustc_parse_format 2025-07-21 09:46:53 +03:00
Laurențiu Nicola
d53f0b9382 Revert "Bump rustc-literal-escaper"
This reverts commit 9f3adc540b51a4c2d0472d94033f6d9147b36f6e.
2025-07-21 09:31:28 +03:00
Laurențiu Nicola
9f3adc540b Bump rustc-literal-escaper 2025-07-21 09:27:37 +03:00
Hayashi Mikihiro
6f101d9cc7 Migrate AstNodeEdit 2025-07-21 15:26:48 +09:00
Laurențiu Nicola
30333a637c Bump rustc crates 2025-07-21 09:19:24 +03:00
Laurențiu Nicola
99894ccbcc Merge from rust-lang/rust 2025-07-21 09:18:22 +03:00
Laurențiu Nicola
d105b7e0d1 Preparing for merge from rust-lang/rust 2025-07-21 09:17:54 +03:00
Shoyu Vanilla (Flint)
28ac05d8ed
Merge pull request #20256 from A4-Tacks/gen-mut-trait-deref
Add Deref -> DerefMut for generate_mut_trait_impl
2025-07-21 04:31:24 +00:00
Shoyu Vanilla (Flint)
ba425ccfa4
Merge pull request #20262 from ChayimFriedman2/goto-ref-raw
fix: Fix search of raw labels and lifetimes
2025-07-21 04:30:42 +00:00
The rustc-josh-sync Cronjob Bot
de49ed5ae6 Merge ref '460259d14de0' from rust-lang/rust
Pull recent changes from https://github.com/rust-lang/rust via Josh.

Upstream ref: 460259d14de0274b97b8801e08cb2fe5f16fdac5
Filtered ref: 599ee17eb87c83f97eb37fd9fe264da65d4c9461

This merge was created using https://github.com/rust-lang/josh-sync.
2025-07-21 04:17:50 +00:00
Laurențiu Nicola
58e507d807
Merge pull request #20255 from A4-Tacks/deref-intranstive
Fix ide-assist: generate Deref transitive
2025-07-21
2025-07-20 10:54:35 +00:00
Laurențiu Nicola
63c1b72939
Merge pull request #20265 from ChayimFriedman2/cfg-select
feat: Support `cfg_select!`
2025-07-20 10:48:40 +00:00
Chayim Refael Friedman
b1914e420f Support cfg_select! 2025-07-20 11:56:45 +03:00
bors
f13fe5a4dc Auto merge of #144068 - dianqk:update-llvm, r=cuviper
Update LLVM submodule

Fixes for https://rust-lang.zulipchat.com/#narrow/stream/187780-t-compiler.2Fllvm/topic/Backporting.20LLVM.20fix.20for.20Wasm.20EH.3F/near/528879210.
2025-07-20 06:45:43 +00:00
Chayim Refael Friedman
7723b21c3f Fix search of raw labels and lifetimes
It used to search for `'foo` which won't find `'r#foo`, now we search for `foo` instead.
2025-07-20 01:20:09 +03:00
bors
812f0d4da5 Auto merge of #143641 - Kobzol:tool-target, r=jieyouxu
Add `ToolTarget` to bootstrap

Oh, you thought I'm done with refactoring bootstrap tools? Na-ah, think again! After the failure of https://github.com/rust-lang/rust/pull/143581, `ToolTarget` is back with a vengeance. This time, I implemented the test changes and tool cleanups without forcing these tools to be built with the stage0 compiler.

There are still some small wins though, `LlvmBitcodeLinker` now starts at stage 1, and not stage 2. Cargo should also be ported to this new mode, but I'm leaving that for a follow-up PR.

Hopefully X-th time's the charm 🤞

r? `@jieyouxu`
2025-07-19 14:09:56 +00:00
Laurențiu Nicola
ed193af369
Merge pull request #20258 from Young-Flash/remove_unused
minor: remove unused var
2025-07-19 08:30:24 +00:00
Young-Flash
0901631095 minor: remove unused var 2025-07-19 16:19:20 +08:00
bors
8281302563 Auto merge of #143784 - scottmcm:enums-again-new-ex2, r=dianqk
Simplify discriminant codegen for niche-encoded variants which don't wrap across an integer boundary

Inspired by rust-lang/rust#139729, this attempts to be a much-simpler and more-localized change while still making a difference.  (Specifically, this does not try to solve the problem with select-sinking, leaving that to be fixed by https://github.com/llvm/llvm-project/issues/134024 -- once it gets released -- instead of in rustc's codegen.)

What this *does* improve is checking for the variant in a 3+ variant enum when that variant is the type providing the niche.  Something like `if let Foo::WithBool(_) = ...` previously compiled to `ugt(add(x, -2), 2)`, which is non-trivial to think about because it's depending on the unsigned wrapping to shift the 0/1 up above 2.  With this PR it compiles to just `ult(x, 2)`, which is probably what you'd have written yourself if you were doing it by hand to look for "is this byte a bool?".

That's done by leaving most of the codegen alone, but adding a couple new special cases to the `is_niche` check.  The default looks at the relative discriminant, but in the common cases where there's no wraparound involved, we can just check the original value, rather than the offsetted one.

The first commit just adds some tests, so the best way to see the effect of this change is to look at the second commit and how it updates the test expectations.
2025-07-19 08:03:40 +00:00
A4-Tacks
dfd8434847
Add Deref -> DerefMut for generate_mut_trait_impl 2025-07-19 15:01:13 +08:00