aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* nail rowan version downBernhard Schuster2021-04-171-1/+1
| | | The different pre versions include breaking changes, which cause build failures for the users.
* Merge #8550bors[bot]2021-04-173-48/+35
|\ | | | | | | | | | | | | | | | | | | 8550: Handle extended key value attributes in mbe r=edwin0cheng a=edwin0cheng fixes #8544 bors r+ Co-authored-by: Edwin Cheng <[email protected]>
| * Handle extended key value attr in mbeEdwin Cheng2021-04-173-48/+35
|/
* Merge #8549bors[bot]2021-04-172-2/+72
|\ | | | | | | | | | | | | | | | | | | 8549: Fix `TestDB::module_at_position` with submodules r=jonas-schievink a=jonas-schievink Found while looking into https://github.com/rust-analyzer/rust-analyzer/issues/8519 bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * Fix `TestDB::module_at_position` with submodulesJonas Schievink2021-04-172-2/+72
|/
* Merge #8546bors[bot]2021-04-162-2/+35
|\ | | | | | | | | | | | | | | | | 8546: Return CallInfo for unclosed call expressions r=Veykril a=Veykril Closes #8522 bors r+ Co-authored-by: Lukas Wirth <[email protected]>
| * Return CallInfo for unclosed call expressionsLukas Wirth2021-04-162-2/+35
| |
* | Merge #8542bors[bot]2021-04-168-20/+40
|\ \ | | | | | | | | | | | | | | | | | | | | | 8542: Include path in `unresolved-macro-call` diagnostic r=matklad a=jonas-schievink Co-authored-by: Jonas Schievink <[email protected]>
| * | Include path in `unresolved-macro-call` diagnosticJonas Schievink2021-04-168-20/+40
| |/
* | Merge #8539bors[bot]2021-04-165-7/+53
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | 8539: fix: Do not propose inherent traits in flyimports and import assists r=flodiebold a=SomeoneToIgnore Closes https://github.com/rust-analyzer/rust-analyzer/issues/8520 I've went with a separate method approach, since the [highlighted code](https://github.com/rust-analyzer/rust-analyzer/issues/8520#issuecomment-819856337) has not`Type` and uses `Ty` to get his data, but the code I had to change has no access to `Ty` and has `Type` only. Co-authored-by: Kirill Bulatov <[email protected]>
| * | Exclude inherent traits from flyimportsKirill Bulatov2021-04-165-7/+53
| |/
* | Merge #8545bors[bot]2021-04-162-1/+25
|\ \ | | | | | | | | | | | | | | | | | | | | | 8545: Fix primitive shadowing with inner items r=jonas-schievink a=jonas-schievink bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * | Fix primitive shadowing with inner itemsJonas Schievink2021-04-162-1/+25
|/ /
* | Merge #8543bors[bot]2021-04-162-16/+24
|\ \ | |/ |/| | | | | | | | | | | | | 8543: Assist fix: Fill match arms for a tuple of a single enum. r=Veykril a=iDawer This is rather a small fix addressing an issue mentioned in https://github.com/rust-analyzer/rust-analyzer/issues/8493#issuecomment-818770670 Co-authored-by: Dawer <[email protected]>
| * Fill match arms for a tuple of a single enum.Dawer2021-04-162-16/+24
| |
* | Merge #8536bors[bot]2021-04-151-4/+4
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8536: change grammar r=kjeremy a=Milo123459 indexing -> Indexing fetching -> Fetching loading -> Loading roots scanned -> Roots Scanned Co-authored-by: Milo <[email protected]>
| * | change grammarMilo2021-04-151-4/+4
|/ /
* | Merge #8535bors[bot]2021-04-151-3/+3
|\ \ | | | | | | | | | | | | | | | | | | | | | 8535: Fix markdown links r=jonas-schievink a=jonas-schievink bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * | Fix markdown linksJonas Schievink2021-04-151-3/+3
|/ /
* | Merge #8534bors[bot]2021-04-151-6/+0
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | 8534: Remove unneeded annotations from find_path tests r=jonas-schievink a=jonas-schievink Addresses https://github.com/rust-analyzer/rust-analyzer/pull/8532#discussion_r614247375 bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * | Remove unneeded annotations from find_path testsJonas Schievink2021-04-151-6/+0
|/ /
| |
| \
*-. \ Merge #8510 #8533bors[bot]2021-04-158-75/+84
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8510: Move cursor position when using item movers r=jonas-schievink a=jonas-schievink This updates the cursor position when moving items around to stay in the same location within the moved node. I changed the `moveItem` response to `SnippetTextEdit[]`, since that made more sense to me (the file was ignored by the client anyways, since the edits always apply to the current document). It also matches `onEnter`, which seems logical to me, but please let me know if this doesn't make sense. There's still a bug in the client-side snippet code that will cause the cursor position to be slightly off when moving parameters in the same line (presumably we don't track the column correctly after deleting `$0`). Not really sure how to fix that immediately, but this PR should already be an improvement despite that bug. 8533: Fix typo in style guide r=jonas-schievink a=jonas-schievink Fixes bold text rendering bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| | * | Fix typo in style guideJonas Schievink2021-04-151-1/+1
| | | |
| * | | Move cursor position when using item moversJonas Schievink2021-04-137-74/+83
| | | |
* | | | Merge #8532bors[bot]2021-04-151-260/+327
|\ \ \ \ | |_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | 8532: Make `find_path` tests adhere to style guide r=jonas-schievink a=jonas-schievink bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * | | Make find_path tests adhere to style guideJonas Schievink2021-04-151-260/+327
|/ / /
* | | Merge #8529bors[bot]2021-04-152-3/+3
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | | | | 8529: minor: notify 5.0.0.pre7 r=kjeremy a=kjeremy Fixes windows leak: https://github.com/notify-rs/notify/pull/298 Co-authored-by: kjeremy <[email protected]>
| * | Update license checkkjeremy2021-04-151-1/+1
| | |
| * | notify 5.0.0.pre7kjeremy2021-04-151-2/+2
|/ / | | | | | | Fixes windows leak: https://github.com/notify-rs/notify/pull/298
* | Merge #8526bors[bot]2021-04-151-0/+50
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8526: fix: Do not show flyimports in trait or impl declarations r=SomeoneToIgnore a=SomeoneToIgnore Part of https://github.com/rust-analyzer/rust-analyzer/issues/8518 Removes autoimport suggestions for the case: > inside trait definitions / impls (trait Trait {$0} / impl Foo {$0}), nothing except the fn, type and const keywords (and the full item completions for trait impls) should appear (currently many types and autoimport suggestions) Co-authored-by: Kirill Bulatov <[email protected]>
| * | Do not show flyimports in trait or impl declarationsKirill Bulatov2021-04-151-0/+50
|/ /
* | Merge #8515bors[bot]2021-04-143-6/+20
|\ \ | | | | | | | | | | | | | | | | | | | | | 8515: internal: Profile trait solving for all invocations r=flodiebold a=SomeoneToIgnore Follow-up of https://github.com/rust-analyzer/rust-analyzer/pull/8514#issuecomment-819610492 Co-authored-by: Kirill Bulatov <[email protected]>
| * | Profile trait solving for all invocationsKirill Bulatov2021-04-143-6/+20
|/ /
* | Merge #8514bors[bot]2021-04-141-1/+6
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | 8514: Add more profiling spans into type inference r=matklad a=SomeoneToIgnore Fixes https://github.com/rust-analyzer/rust-analyzer/issues/8503 I've added a minimal set of spans to remove `???` and showcase the underlying issue: <img width="1552" alt="image" src="https://user-images.githubusercontent.com/2690773/114722983-f2181900-9d42-11eb-821d-9e93ded5f81f.png"> `db.trait_solve` reliably produces the same timings for the same input in the same place for me, despite supposedly being cached by Salsa. In my perception, this is a bit odd, so I've decided to stop at this point and discuss it with people with better knowledge on the topic. Co-authored-by: Kirill Bulatov <[email protected]>
| * Better places for spansKirill Bulatov2021-04-141-2/+1
| |
| * We need to go deeperKirill Bulatov2021-04-141-1/+5
| |
| * Add a missing spanKirill Bulatov2021-04-141-0/+2
|/
* Merge #8507bors[bot]2021-04-131-96/+104
|\ | | | | | | | | | | | | | | 8507: internal: follow test style guide in typing.rs r=jonas-schievink a=jonas-schievink bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * internal: follow test style guide in typing.rsJonas Schievink2021-04-131-96/+104
| |
* | Merge #8506bors[bot]2021-04-131-2/+2
|\ \ | |/ |/| | | | | | | | | | | 8506: crossbeam-channel 0.5.1 r=kjeremy a=kjeremy Fixes a potential memory leak in unbound channels. Co-authored-by: kjeremy <[email protected]>
| * crossbeam-channel 0.5.1kjeremy2021-04-131-2/+2
| | | | | | | | Fixes a potential memory leak in unbound channels.
* | Merge #8504bors[bot]2021-04-131-60/+59
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | 8504: decl_check: follow test style guide r=jonas-schievink a=jonas-schievink changelog skip bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * | decl_check: follow test style guideJonas Schievink2021-04-131-60/+59
|/ /
* | Merge #8432bors[bot]2021-04-133-15/+151
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8432: decl_check: consider outer scopes' allows r=jonas-schievink a=lf- Fix #8417. Also makes it less noisy about no_mangle annotated stuff the user can do nothing about. Note: this still is broken with bitfield! macros. A repro in an ignore test is included here. I believe this bug is elsewhere, and I don't think I can work around it here. I would like help filing the remaining bug, as it does actually affect users, but I don't know how to describe the behaviour (or even if it is unintended). Co-authored-by: Jade <[email protected]>
| * address review feedbackJade2021-04-131-21/+35
| |
| * decl_check: consider outer scopes' allowsJade2021-04-083-11/+133
| | | | | | | | | | | | | | | | | | Fix #8417. Also makes it less noisy about no_mangle annotated stuff the user can do nothing about. Note: this still is broken with bitfield! macros. A repro in an ignore test is included here. I believe this bug is elsewhere, and I don't think I can work around it here.
* | Merge #8354bors[bot]2021-04-137-21/+87
|\ \ | | | | | | | | | | | | | | | | | | | | | 8354: Distinguishing between different operators in semantic highlighting r=matklad a=chetankhilosiya Co-authored-by: Chetan Khilosiya <[email protected]>
| * | 8279: Fix the not operator use and test case fix.Chetan Khilosiya2021-04-083-10/+3
| | |
| * | 8279: Added initial implementation forChetan Khilosiya2021-04-085-19/+92
| | | | | | | | | | | | Operator semantic highlighting.
* | | Merge #8415bors[bot]2021-04-131-2/+46
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8415: Fix faulty assertion when extracting function with macro call r=matklad a=brandondong **Reproduction:** ```rust fn main() { let n = 1; let k = n * n; dbg!(n); } ``` 1. Select the second and third lines of the main function. Use the "Extract into function" code assist. 2. Panic occurs in debug, error is logged in release: "[ERROR ide_assists::handlers::extract_function] assertion failed: matches!(path, ast :: Expr :: PathExpr(_))". 3. Function generates successfully on release where the panic was bypassed. ```rust fn fun_name(n: i32) { let k = n * n; dbg!(n); } ``` **Cause:** - The generated function will take `n` as a parameter. The extraction logic needs to search the usages of `n` to determine whether it is used mutably or not. The helper `path_element_of_reference` is called for each usage but the second usage is a macro call and fails the `Expr::PathExpr(_)` match assertion. - The caller of `path_element_of_reference` does implicitly assume it to be a `Expr::PathExpr(_)` in how it looks at its parent node for determining whether it is used mutably. This logic will not work for macros. - I'm not sure if there are any other cases besides macros where it could be something other than a `Expr::PathExpr(_)`. I tried various examples and could not find any. **Fix:** - Update assertion to include the macro case. - Add a FIXME to properly handle checking if a macro usage requires mutable access. For now, return false instead of running the existing logic that is tailored for `Expr::PathExpr(_)`'s. Co-authored-by: Brandon <[email protected]>