34905 Commits

Author SHA1 Message Date
David Barsky
98f32c1de1 hir-ty: add incremental tests checking for infer invalidation 2025-06-03 13:48:45 -04:00
bors
76cf3584c3 Auto merge of #141961 - matthiaskrgr:rollup-r09j2sp, r=matthiaskrgr
Rollup of 8 pull requests

Successful merges:

 - rust-lang/rust#141724 (fix(rust-lang/rust#141141): When expanding `PartialEq`, check equality of scalar types first.)
 - rust-lang/rust#141833 (`tests/ui`: A New Order [2/N])
 - rust-lang/rust#141861 (Switch `x86_64-msvc-{1,2}` back to Windows Server 2025 images)
 - rust-lang/rust#141914 (redesign stage 0 std follow-ups)
 - rust-lang/rust#141918 (Deconstruct values in the THIR visitor)
 - rust-lang/rust#141923 (Update books)
 - rust-lang/rust#141931 (Deconstruct values in the THIR visitor)
 - rust-lang/rust#141956 (Remove two trait methods from cg_ssa)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-06-03 16:31:44 +00:00
Shoyu Vanilla
4b39ff6aea ci: Pin cargo-workspaces to 0.3.6 2025-06-04 00:14:00 +09:00
bors
cdcca68936 Auto merge of #136942 - Kobzol:stage0-sccache, r=jieyouxu
Use ccache for stage0 tool builds

Now after the stage0 redesign, we can actually start ccaching the build of the compiler itself. We can also cache the bootstrap tools, since these are also built with the stage0 compiler.

Stage0 compiler builds are now being cached: https://github.com/rust-lang/rust/actions/runs/15397246267#summary-43321151192 (`..bootstrap::core::build_steps::compile::Rustc	483.10s	40.41s	-91.6%`). It's not a gigantic win everywhere, but it should help. It seems to make the Linux jobs ~10 minute faster. It should be especially useful on PR builds after https://github.com/rust-lang/rust/pull/141948.

r? `@jieyouxu`

try-job: `x86_64-gnu-llvm-19*`
try-job: `x86_64-msvc*`
try-job: `x86_64-apple*`
try-job: `dist-x86_64-linux`
2025-06-03 13:09:57 +00:00
bors
96ac9469b1 Auto merge of #141954 - matthiaskrgr:rollup-zptd6t9, r=matthiaskrgr
Rollup of 9 pull requests

Successful merges:

 - rust-lang/rust#141554 (Improve documentation for codegen options)
 - rust-lang/rust#141817 (rustc_llvm: add Windows system libs only when cross-compiling from Wi…)
 - rust-lang/rust#141843 (Add `visit_id` to ast `Visitor`)
 - rust-lang/rust#141881 (Subtree update of `rust-analyzer`)
 - rust-lang/rust#141898 ([rustdoc-json] Implement PartialOrd and Ord for rustdoc_types::Id)
 - rust-lang/rust#141921 (Disable f64 minimum/maximum tests for arm 32)
 - rust-lang/rust#141930 (Enable triagebot `[concern]` functionality)
 - rust-lang/rust#141936 (Decouple "reporting in deps" from `FutureIncompatibilityReason`)
 - rust-lang/rust#141949 (move `test-float-parse` tool into `src/tools` dir)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-06-03 09:51:59 +00:00
Matthias Krüger
77bbfd4195
Rollup merge of #141949 - onur-ozkan:move-test-float-parse, r=Kobzol
move `test-float-parse` tool into `src/tools` dir

Obviously `test-float-parse` is a tool like any other in `src/tools`.

cc `@tgross35`
2025-06-03 11:33:37 +02:00
Matthias Krüger
9711a3bd3c
Rollup merge of #141936 - WaffleLapkin:report-in-deps-decoupling, r=oli-obk
Decouple "reporting in deps" from `FutureIncompatibilityReason`

The reason should just be it -- the reason. It never felt right to me that it was also responsible for whatever we include the warning in cargo's reports.

It gets especially unruly if you want to add non-`FutureReleaseError*` warnings which are included in the reports.

I just added a field to `FutureIncompatibleInfo` to control whatever the diagnostic is included in the cargo's reports.
2025-06-03 11:33:36 +02:00
Matthias Krüger
37b8899231
Rollup merge of #141930 - Urgau:triagebot_concern, r=Kobzol
Enable triagebot `[concern]` functionality

Documentation at: https://forge.rust-lang.org/triagebot/concern.html
Example at: https://github.com/rust-lang/triagebot/pull/2024

r? Kobzol
2025-06-03 11:33:36 +02:00
Matthias Krüger
83d145cc77
Rollup merge of #141921 - ehuss:arm-min-max, r=tgross35
Disable f64 minimum/maximum tests for arm 32

This disables the f64 minimum/maximum tests for the arm-unknown-linux-gnueabihf job. The next release will be supporting cross-compiled doctests, and these tests fail on that platform.

It looks like this was just fixed via https://github.com/llvm/llvm-project/pull/142170, but I assume that will not trickle down to our copy of llvm in the next couple of weeks. Assuming that does get fixed when llvm is updated, then these can be removed.

cc https://github.com/rust-lang/rust/issues/141087
2025-06-03 11:33:35 +02:00
Matthias Krüger
1ebd724689
Rollup merge of #141898 - LukeMathWalker:patch-1, r=aDotInTheVoid
[rustdoc-json] Implement PartialOrd and Ord for rustdoc_types::Id

This allows consumers to create collections that required an ordering relationship for their keys—e.g. a `BTreeMap`.
2025-06-03 11:33:35 +02:00
Matthias Krüger
c029c2e8d8
Rollup merge of #141881 - lnicola:sync-from-ra, r=lnicola
Subtree update of `rust-analyzer`

r? `@ghost`
2025-06-03 11:33:34 +02:00
dependabot[bot]
8a301b6991
chore(deps): bump tar-fs from 2.1.2 to 2.1.3 in /editors/code
Bumps [tar-fs](https://github.com/mafintosh/tar-fs) from 2.1.2 to 2.1.3.
- [Commits](https://github.com/mafintosh/tar-fs/commits)

---
updated-dependencies:
- dependency-name: tar-fs
  dependency-version: 2.1.3
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-03 09:11:14 +00:00
Lukas Wirth
cf969d21c3
Merge pull request #19869 from MatrixFrog/publicize_field
Add a quickfix for accessing a private field of a struct
2025-06-03 06:11:28 +00:00
Lukas Wirth
ed2ae943bb
Merge pull request #19894 from ShoyuVanilla/some-query-cycles
fix: Cycle handlers for `HirDatabase::infer, const_param_ty_with_diagnostics`
2025-06-03 06:08:46 +00:00
Lukas Wirth
9edac77f48
Merge pull request #19901 from BazookaMusic/master
Enable Assist edit for tuple<->named struct for the struct and visiblity keywords
2025-06-03 06:07:39 +00:00
Tyler Breisacher
4055436776 Add a quickfix for accessing a private field of a struct 2025-06-02 22:45:34 -07:00
bors
2ccdc409d4 Auto merge of #141210 - RalfJung:miri-std-doctests, r=saethlin
tools-aux ci runner: also cross-test doctests in Miri

Miri now supports running doctests across different targets. Let's use that to run the std doctests on aarch64-apple-darwin, i686-pc-windows-msvc.

try-job: x86_64-gnu-aux
2025-06-03 03:14:19 +00:00
Shoyu Vanilla
fefe86732d fix: Cycle handlers for `HirDatabase::infer, const_param_ty_with_diagnostics 2025-06-03 10:39:38 +09:00
Ryan Mehri
7e8079fbad feat: implement completion for diagnostic module 2025-06-02 20:56:20 -04:00
BazookaMusic
34b31f174d simplify expression that checks the offset 2025-06-02 23:28:26 +02:00
Ryan Mehri
fb921c3039 fix: don't duplicate must_use for functions and traits 2025-06-02 15:35:13 -04:00
Lukas Wirth
25808c1ba1
Merge pull request #19893 from Veykril/push-wzqsompmnlmx
Enhance renaming to include identifiers that are generated from the original symbol
2025-06-02 13:39:04 +00:00
Lukas Wirth
9a786d0008 Support derive-macros for rename prefix magic 2025-06-02 15:27:13 +02:00
Lukas Wirth
96c4455114 fix: Fix edition handling for names in rename logic 2025-06-02 15:27:13 +02:00
Lukas Wirth
42e8e4ac4e Enhance renaming to include identifiers that are generated from the original symbol
Co-authored-by: Jake Goulding <jake.goulding@integer32.com>
2025-06-02 15:26:21 +02:00
Lukas Wirth
04439c8cce
Merge pull request #19904 from Wilfred/project_json_naming
internal: Use 'ProjectJson' consistently
2025-06-02 11:13:14 +00:00
Wilfred Hughes
005d8c59ab internal: Use 'ProjectJson' consistently
The Rust source code previously mised ProjectJson and JsonProject,
and the TypeScript definition didn't match either.

Use 'ProjectJson' everywhere. This is purely an internal change.
2025-06-02 11:21:46 +01:00
Lukas Wirth
b9e6671353
Merge pull request #19897 from aibaars/patch-2
Produce ClosureBinder node in atom.rs
2025-06-02 09:13:04 +00:00
bors
ec7153fad3 Auto merge of #141725 - nnethercote:avoid-UsePath-overcounting, r=BoxyUwU
Avoid over-counting of `UsePath` in the HIR stats.

Currently we over-count. Details in the individual commits.

r? `@BoxyUwU`
2025-06-01 04:21:50 +00:00
BazookaMusic
5caf570d40 clippy and more formatting 2025-06-01 01:20:45 +02:00
BazookaMusic
03276f8a24 rename function so it makes more sense 2025-06-01 01:16:37 +02:00
BazookaMusic
41cd1732b7 Formatting issues resolved 2025-06-01 01:09:23 +02:00
BazookaMusic
7b200890c4 add missing public keyword 2025-06-01 00:47:43 +02:00
BazookaMusic
43072c3a0b Allow assist edit for converting structs to appear also on struct keyword and on visibility 2025-06-01 00:44:33 +02:00
bors
1a2aef4465 Auto merge of #141685 - orlp:inplace-tls-drop, r=joboet
Do not move thread-locals before dropping

Fixes rust-lang/rust#140816. I also (potentially) improved the speed of `get_or_init` a bit by having an explicit hot/cold path.

We still move the value before dropping in the event of a recursive initialization (leading to double-initialization with one value being silently dropped). This is the old behavior, but changing this to panic instead would involve changing tests and also the other OS-specific `thread_local/os.rs` implementation, which is more than I'd like in this PR.
2025-05-31 14:56:33 +00:00
Lukas Wirth
2a388d1103
Merge pull request #19900 from Veykril/push-zurosouxqxzz
fix: Fix manual not containing diagnostics documentation
2025-06-02
2025-05-31 12:47:26 +00:00
Lukas Wirth
62bacfc37b fix: Fix manual not containing diagnostics documentation 2025-05-31 14:36:29 +02:00
Lukas Wirth
61f8a8b017
Merge pull request #19899 from SomeoneToIgnore/generate-actions
Account for `Generate` actions when filtering the allowed ones
2025-05-31 12:34:33 +00:00
Kirill Bulatov
4870b6b7c1 Account for Generate actions when filtering the allowed ones 2025-05-31 12:29:50 +03:00
bors
79a2af75f1 Auto merge of #141678 - Kobzol:revert-141516, r=workingjubilee
Revert "increase perf of charsearcher for single ascii characters"

This reverts commit 245bf503e2a948ac98170516d11df632e85a948b (PR https://github.com/rust-lang/rust/pull/141516).

It caused a large `doc` perf. regression in https://github.com/rust-lang/rust/pull/141605.
2025-05-31 08:11:06 +00:00
Lukas Wirth
cdd0ac27e3
Merge pull request #19898 from Veykril/push-ykumpuwmuvmu
refactor: Remove unncessary duplication in highlight_related
2025-05-31 05:35:49 +00:00
Lukas Wirth
9ee761904e refactor: Remove unncessary duplication in highlight_related 2025-05-31 07:25:03 +02:00
bors
24c859a875 Auto merge of #141667 - lqd:lazy-maybe-init, r=matthewjasper
Add fast path for maybe-initializedness in liveness

r? `@matthewjasper`

Correct me if I'm wrong Matthew, but my understanding is that
1. `MaybeInitializedPlaces` is currently eagerly computed, in `do_mir_borrowck`
2. but this data is only used in liveness
3. and `liveness::trace` actually only uses it for drop-liveness

This PR moves the computation to `liveness::trace` which looks to be its only use-site. We also add a fast path there, so that it's only computed by drop-liveness.

This is interesting because 1) liveness is only computed for relevant live locals, 2) drop-liveness is only computed for relevant live locals with >0 drop points; 0 is the common case from our benchmarks, as far as I can tell, so even just computing the entire data lazily helps.

It seems possible to also reduce the domain here, and speed up the analysis for the cases where it has to be computed -- so I've left a fixme for that, and may look into it soon.

(I've come upon this while doing implementation work for polonius, so don't be too enamored with possible wins: the goal is to reduce the eventual polonius overhead and make it more palatable 😓)
2025-05-31 04:52:37 +00:00
Arthur Baars
55328ba9b4 Update expected test output 2025-05-30 21:16:38 +00:00
Arthur Baars
a91b67e682 Run 'cargo codegen' to update tests 2025-05-30 21:05:12 +00:00
Arthur Baars
7f7079f2bf
Add test for closure_binder
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
2025-05-30 22:58:13 +02:00
Arthur Baars
fb16d3b7f8
Produce ClosureBinder node in atom.rs 2025-05-30 22:38:31 +02:00
Lukas Wirth
987cd076e2
Merge pull request #19896 from Veykril/push-qyutrlxyznum
internal: Restructure some semantics APIs for virtual macro files
2025-05-30 20:15:15 +00:00
Lukas Wirth
38bf4b1fe1 internal: Restructure some semantics APIs for virtual macro files 2025-05-30 22:03:04 +02:00
bors
2e6a357330 Auto merge of #141657 - petrochenkov:nobinroot, r=jieyouxu
bootstrap: Remove `bin_root` from `PATH`

It's not currently load bearing in typical setups on typical targets.
Basically, if it passes the standard CI, then we can remove it, I think.

If someone later reports this breaking the build, then we can address it in a more fine grained way.
E.g. add it to `PATH` last and not first, only on specific targets, and only if specific files are not already found in `PATH` directories.

Fixes [#t-infra/bootstrap > Build broken in MSYS2 @ 💬](https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/Build.20broken.20in.20MSYS2/near/520709527)
2025-05-30 18:56:37 +00:00