Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Subtree update of rust-analyzer #129054

Merged
merged 129 commits into from
Aug 14, 2024
Merged

Subtree update of rust-analyzer #129054

merged 129 commits into from
Aug 14, 2024

Conversation

lnicola
Copy link
Member

@lnicola lnicola commented Aug 13, 2024

huntc and others added 30 commits July 28, 2024 16:09
Selects a rust-toolchain declared RA based on its date. The earliest (oldest) RA wins and becomes the one that the workspace uses as a whole.

In terms of precedence:

nightly > stable-with-version > stable

With stable-with-version, we invoke the RA with a `--version` arg and attempt to extract a date. Given the same date as a nightly, the nightly RA will win.
fix: Insert a tail `Ok(())` for expr block instead of wrapping with `Ok`

Fixes rust-lang#17728

When type mismatch is `Result<(), E>, ()` or `Option<()>, ()` and target expr is a block expression, it is more reasonable to insert a wrapped unit - `Ok(())` or `Some(())` - as the tail expression of that block than wrapping the entire block with `Ok` or `Some`
feat: Use oldest rustup rust-analyzer when toolchain override is present

Selects a rust-toolchain declared RA based on its date. The earliest (oldest) RA wins and becomes the one that the workspace uses as a whole.

In terms of precedence:

nightly > stable-with-version > stable

With stable-with-version, we invoke the RA with a `--version` arg and attempt to extract a date. Given the same date as a nightly, the nightly RA will win.

Fixes rust-lang#17663
internal: Remove AbsPathBuf::TryFrom impl that checks too many things at once

rust-lang/rust-analyzer#16889 (comment)
fix: Insert a generic arg for `impl Trait` when lowering generic args

Fixes rust-lang#17191

We are not inserting a generic arg when lowering generics like
```rust
fn foo<T: B<impl A>(..) { ... }
```
but when we are lowering predicates we do;

https://github.com/rust-lang/rust-analyzer/blob/aa00ddcf654a35ba0eafe17247cf189958d33182/crates/hir-ty/src/lower.rs#L1697-L1718
https://github.com/rust-lang/rust-analyzer/blob/aa00ddcf654a35ba0eafe17247cf189958d33182/crates/hir-ty/src/lower.rs#L310

and this mismatch causes index out of bound panic while substituting the predicates
feat: Load sysroot library via cargo metadata

See rust-lang#128534, fixes rust-lang/rust-analyzer#7637

Requires a toolchain from 176e545 2024-08-04 or later to work.
internal: Newtype `ErasedFileAstId`

It wrapping `la_arena::Idx` makes it quite annoying to use
docs: add msvc note to manual

Added note for Windows users to have the latest MSVC to minimize setup issues.

Closes rust-lang#4870
Split out syntax-bridge into a separate crate

This functionality is not really tied to mbe macros, so imo it has no place in that crate.
@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 13, 2024
@rustbot
Copy link
Collaborator

rustbot commented Aug 13, 2024

rust-analyzer is developed in its own repository. If possible, consider making this change to rust-lang/rust-analyzer instead.

cc @rust-lang/rust-analyzer

@lnicola
Copy link
Member Author

lnicola commented Aug 13, 2024

@bors r+ p=1 subtree update

@bors
Copy link
Contributor

bors commented Aug 13, 2024

📌 Commit f96e296 has been approved by lnicola

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 13, 2024
@bors
Copy link
Contributor

bors commented Aug 13, 2024

⌛ Testing commit f96e296 with merge e46ddd3...

bors added a commit to rust-lang-ci/rust that referenced this pull request Aug 13, 2024
Subtree update of `rust-analyzer`

r? `@ghost`

CC `@ShoyuVanilla`
@rust-log-analyzer
Copy link
Collaborator

The job x86_64-msvc-ext failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)

@bors
Copy link
Contributor

bors commented Aug 13, 2024

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Aug 13, 2024
@lnicola
Copy link
Member Author

lnicola commented Aug 14, 2024

@bors retry #128246

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 14, 2024
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Aug 14, 2024
Subtree update of `rust-analyzer`

r? `@ghost`

CC `@ShoyuVanilla`
bors added a commit to rust-lang-ci/rust that referenced this pull request Aug 14, 2024
…iaskrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#128828 (`-Znext-solver` caching)
 - rust-lang#128954 (Explicitly specify type parameter on FromResidual for Option and ControlFlow.)
 - rust-lang#129054 (Subtree update of `rust-analyzer`)
 - rust-lang#129059 (Record the correct target type when coercing fn items/closures to pointers)
 - rust-lang#129071 (Port `run-make/sysroot-crates-are-unstable` to rmake)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors
Copy link
Contributor

bors commented Aug 14, 2024

⌛ Testing commit f96e296 with merge 0f442e2...

@bors
Copy link
Contributor

bors commented Aug 14, 2024

☀️ Test successful - checks-actions
Approved by: lnicola
Pushing 0f442e2 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Aug 14, 2024
@bors bors merged commit 0f442e2 into rust-lang:master Aug 14, 2024
7 checks passed
@rustbot rustbot added this to the 1.82.0 milestone Aug 14, 2024
@lnicola lnicola deleted the sync-from-ra branch August 14, 2024 14:15
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (0f442e2): comparison URL.

Overall result: ✅ improvements - no action needed

@rustbot label: -perf-regression

Instruction count

This is a highly reliable metric that was used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-0.6% [-0.6%, -0.6%] 4
Improvements ✅
(secondary)
-0.4% [-0.5%, -0.2%] 11
All ❌✅ (primary) -0.6% [-0.6%, -0.6%] 4

Max RSS (memory usage)

Results (primary -1.4%, secondary -0.9%)

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-1.4% [-1.4%, -1.4%] 1
Improvements ✅
(secondary)
-0.9% [-0.9%, -0.9%] 3
All ❌✅ (primary) -1.4% [-1.4%, -1.4%] 1

Cycles

Results (secondary 2.9%)

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
2.9% [2.4%, 3.7%] 5
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 751.474s -> 751.854s (0.05%)
Artifact size: 341.45 MiB -> 341.43 MiB (-0.01%)

@jieyouxu
Copy link
Member

#128246

I think this was meant to be #127883 since failed to remove cargo.exe, pinging back for more data points.

@Mark-Simulacrum
Copy link
Member

Not a real perf improvement, delta from bimodality in these benchmarks.

@jieyouxu jieyouxu added the CI-spurious-fail-msvc CI spurious failure: target env msvc label Oct 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI-spurious-fail-msvc CI spurious failure: target env msvc merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.