Rollup of 22 pull requests - #160517
Conversation
But only if the source is code passed to the macro, not code inside the macro.
With `#[allow(rust_analyzer::inactive_code)]`.
See added comment for rationale. Also note that `rand` has defaulted to LE for many years, apparently without any objections.
Currently JsonLinesParser::from_line is called for both stdout and stderr, so trait implementers cannot distinguish stdout and stderr. Define a separate JsonLinesParser::from_stderr_line to make the stdout/stderr distinction explicit, and update use sites. This is not a behaviour change. AI disclosure: Partially written by Codex and GPT-5.5.
…lens fix: Respect `references.exclude[Tests/Imports]` in references lens
feat: Support inactive-code diagnostic in macros
When encountering a for loop that requires a mutable iterator item, we previously suggested changing the method on the iterated expression, but ignored bindings. We now go to the binding's definition and suggest changing the method there too.
```
error[E0594]: cannot assign to `v.v`, which is behind a `&` reference
--> $DIR/suggest-mut-method-for-loop-hashmap.rs:31:9
|
LL | for (_k, v) in x {
| - this iterator yields `&` references
...
LL | v.v += 1;
| ^^^^^^^^ `v` is a `&` reference, so it cannot be written to
|
help: use mutable method
|
LL | let mut x = map.iter_mut();
| ++++
```
Previously we read both stdout and stderr in the discover protocol. Depending on the tool generating rust-project JSON, this meant that a single stderr log message could break discovery. Instead, only look for JSON from the discover command's stdout, and forward stderr to the rust-analyzer logs. Update both the implementation and the discover protocol docs to reflect this behaviour. AI disclosure: Code partly written by GPT-5.5.
fix: Discover protocol should only parse stdout
fix: resolve path on all namespace on resolve_path
I noticed a few "its" versus "it's" grammatical issues, so I've done a pass at fixing obvious grammar issues. AI disclosure: I fixed the first few manually, then asked GPT-5.5 to look for additional cases and kept all the obviously reasonable fixes.
Signed-off-by: Amirhossein Akhlaghpour <m9.akhlaghpoor@gmail.com>
internal: Spelling and grammar fixes
…4-unicode-progress-report fix: make analysis-stats progress bar Unicode-safe
…_a_discriminant_type_larger_than_typeck_s fix: don't pick a discriminant type larger than typeck's
This comment has been minimized.
This comment has been minimized.
Rollup of 22 pull requests try-job: dist-various-1 try-job: test-various try-job: x86_64-gnu-aux try-job: x86_64-gnu-llvm-21-3 try-job: x86_64-msvc-1 try-job: aarch64-apple try-job: x86_64-mingw-1 try-job: i686-msvc-*
|
@bors p=10 |
|
@JonathanBrouwer If this goes first, this will conflict with the clippy subtree update which will need to be made again from scratch because of a conflict in |
This comment has been minimized.
This comment has been minimized.
What is this?This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.Comparing 1ed2df6 (parent) -> 7218ebe (this PR) Test differencesShow 952 test diffsStage 0
Stage 1
Stage 2
(and 128 additional test diffs) Additionally, 724 doctest diffs were found. These are ignored, as they are noisy. Job group index
Test dashboardRun cargo run --manifest-path src/ci/citool/Cargo.toml -- \
test-dashboard 7218ebe93668f51a94a572b690c433dfdbdc2c3d --output-dir test-dashboardAnd then open Job duration changes
How to interpret the job duration changes?Job durations can vary a lot, based on the actual runner instance |
|
📌 Perf builds for each rolled up PR:
previous master: 1ed2df61a1 In the case of a perf regression, run the following command for each PR you suspect might be the cause: |
@samueltardieu Oops, I literally only just woke up so I didn't get the chance to let you go first, sorry. |
|
Finished benchmarking commit (7218ebe): comparison URL. Overall result: ❌ regressions - please read:Our benchmarks found a performance regression caused by this PR. Next Steps:
@rustbot label: +perf-regression Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary -0.5%, secondary 1.1%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary 1.0%, secondary 0.4%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeResults (primary 0.6%, secondary 1.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Bootstrap: 489.825s -> 496.187s (1.30%) |
Successful merges:
rust-analyzersubtree update #160426 (rust-analyzersubtree update)readdiron nearly all UNIX platforms #158727 (std: usereaddiron nearly all UNIX platforms)tests/ui/issues! #160176 (No moretests/ui/issues!)E-needs-test#160407 (Add regression tests for a number of ICEs and diagnostics issues labelledE-needs-test)core::io&alloc::ioDocumentation #160472 (Minor fixes tocore::io&alloc::ioDocumentation)FreeRegionsVisitor#160486 (Remove unusedFreeRegionsVisitor)Failed merges:
r? @ghost
Create a similar rollup