-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
⬆️ rust-analyzer #104454
Closed
Closed
⬆️ rust-analyzer #104454
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Previously, when triggering a method extraction from within a trait impl block, then this would always create a new impl block for the struct, even if there already is one. Now, it'll put the extracted method in the matching existing block if it exists.
…kril internal: Use a process group for flycheck Should fix rust-lang/rust-analyzer#13348
internal: Optimize `apply_document_changes` a bit cc rust-lang/rust-analyzer#13538
minor: Fix typos
…it-into-impl-root, r=Veykril Feat: extracted method from trait impl is placed in existing impl **Before** https://user-images.githubusercontent.com/1759192/183872883-3b0eafd2-d1dc-440e-9e66-38e3372f8b64.mp4 **After** https://user-images.githubusercontent.com/1759192/183875769-87f34c7d-52f0-4dfc-9766-f591ee738ebb.mp4 Previously, when triggering a method extraction from within an impl trait block, then this would always create a new impl block for the struct, even if there already is one. Now, if there is already an existing trait-less impl block, then it'll put the extracted method in there. **Caveats**: - It currently requires the target impl block to be non-empty. This limitation is because the current architecture takes a `node_to_insert_after` as reference for where to insert the extracted function. An empty impl block doesn't have such a reference node, since it's empty. It seems that supporting this requires a much larger and more complex change. - This is my first contribution in rust, so apologies for any beginner mistakes.
The length of byte strings containing escaped newlines is displayed two bytes longer when the first escaped character is a newline. This is due to a small bug in handling the first escaped newline in string literals. Closes rust-lang#13567
Update sysroot crates
Thanks to Lukas Wirth for a suggestion.
Bump Cargo rust-version fields to latest stable We already depend on `let ... else` now anyways Closes rust-lang/rust-analyzer#13562
Generalize reborrow hints as adjustment hints Like reborrow hints, these are still mainly useful for teaching/learning ![image](https://user-images.githubusercontent.com/3757771/200073606-b5cd3b95-a9ad-454d-a3c4-d4d89bf45928.png)
minor: Remove code duplication
…escaped-newlines, r=Veykril Fix the length displayed for byte string literals with escaped newlines This is a fix for the problem I reported earlier: "the length of byte strings containing escaped newlines is displayed two bytes longer when the first escaped character is a newline". I would appreciate it if you could review the fix. Many thanks. Closes rust-lang#13567
fix: Send status notification if there are no found workspaces Closes rust-lang/rust-analyzer#5829
Fix `tt::Punct`'s spacing calculation Fixes rust-lang#13499 We currently set a `tt::Punct`'s spacing to `Spacing::Joint` unless its next token is a trivia (i.e. whitespaces or comment). As I understand it, rustc only [sets `Spacing::Joint` if the next token is an operator](https://github.com/rust-lang/rust/blob/5b3e9090757da9a95b22f589fe39b6a4b5455b96/compiler/rustc_parse/src/lexer/tokentrees.rs#L77-L78) and we should follow it to guarantee the consistent behavior of proc macros.
…y, r=Veykril fix: check visibility of each path segment Upon path resolution, we have not been checking if every def pointed to by each segment of the path is visible from the original module. This leads to incorrect import resolutions, in particular when one uses glob imports and names collide. There is decent amount of changes in this PR because: - some of our tests were not correct in terms of visibility - I left several basic nameres tests as-is (with expect test updated) since I thought it would be nice to ensure we don't resolve defs that are not visible. - `fix_visibility` assist relied on `Semantics::resolve_path()`, which uses the name resolution procedure I'm fixing and wouldn't be able to "see through" the items with strict visibility with this patch The first commit is the gist of the fix itself. Fixes rust-lang#10991 Fixes rust-lang#11473 Fixes rust-lang#13252
fix: Fix hover in attributed items not preferring similar kinded tokens
fix: Fix r-a eagerly showing no discovered workspace errors
fix: Add trait alias grammar to rust.ungram We already parse them, but the grammar was never updated to reflect that
internal: Add version info to unsupported proc macro abi error cc rust-lang/rust-analyzer#13589 (comment)
rustbot
added
the
S-waiting-on-review
Status: Awaiting review from the assignee but also interested parties.
label
Nov 15, 2022
@bors r+ rollup |
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
Nov 15, 2022
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this pull request
Nov 16, 2022
…r=lnicola ⬆️ rust-analyzer r? `@ghost`
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this pull request
Nov 16, 2022
…r=lnicola ⬆️ rust-analyzer r? ``@ghost``
bors
added
S-waiting-on-author
Status: This is awaiting some action (such as code changes or more information) from the author.
and removed
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
labels
Nov 16, 2022
bors
added a commit
to rust-lang/rust-analyzer
that referenced
this pull request
Nov 16, 2022
internal: Update proc-macro-srv tests Should have been included in #13548, but I didn't notice as those tests aren't run in our CI. cc rust-lang/rust#104454
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
S-waiting-on-author
Status: This is awaiting some action (such as code changes or more information) from the author.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
r? @ghost