aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | | | Merge #8572bors[bot]2021-04-191-2/+3
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8572: minor: update bug report template r=lnicola a=lnicola bors r+ Co-authored-by: LaurenČ›iu Nicola <[email protected]>
| * | | | | | | | Update bug report templateLaurențiu Nicola2021-04-191-2/+3
|/ / / / / / / /
* | | | | | | | Merge #8467bors[bot]2021-04-196-0/+269
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8467: Adds impl Deref assist r=jhgg a=jhgg This PR adds a new `generate_deref` assist that automatically generates a deref impl for a given struct field. Check out this gif: ![2021-04-11_00-33-33](https://user-images.githubusercontent.com/5489149/114296006-b38e1000-9a5d-11eb-9112-807c01b8fd0a.gif) -- I have a few Q's: - [x] Should I write more tests, if so, what precisely should I test for? - [x] I have an inline question on line 65, can someone provide guidance? :) - [x] I can implement this for `ast::TupleField` too. But should it be a separate assist fn, or should I try and jam both into the `generate_deref`? - [x] I want to follow this up with an assist on `impl $0Deref for T {` which would automatically generate a `DerefMut` impl that mirrors the Deref as well, however, I could probably use some pointers on how to do that, since I'll have to reach into the ast of `fn deref` to grab the field that it's referencing for the `DerefMut` impl. Co-authored-by: jake <[email protected]>
| * | | | | | | | implement field stuff toojake2021-04-191-22/+106
| | | | | | | | |
| * | | | | | | | Adds impl Deref assistjake2021-04-116-0/+185
| | | | | | | | |
* | | | | | | | | Merge #8569bors[bot]2021-04-194-18/+83
|\ \ \ \ \ \ \ \ \ | |_|_|_|_|_|_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8569: Support inherent impls in unnamed consts r=jonas-schievink a=jonas-schievink It turns out that some proc. macros not only generate *trait* impls wrapped in `const _: () = { ... };`, but inherent impls too. Even though it is questionable whether *custom derives* should produce non-trait impls, this is useful for procedural attribute macros once we support them. bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * | | | | | | | Collect inherent impls in unnamed constsJonas Schievink2021-04-192-17/+62
| | | | | | | | |
| * | | | | | | | Fix visibility of items in block modulesJonas Schievink2021-04-192-1/+21
|/ / / / / / / /
* | | | | | | | Merge #8564bors[bot]2021-04-182-0/+11
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8564: Expand `global_asm!` to nothing r=jonas-schievink a=jonas-schievink fixes https://github.com/rust-analyzer/rust-analyzer/issues/8563 bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * | | | | | | | Expand `global_asm!` to nothingJonas Schievink2021-04-182-0/+11
| | | | | | | | |
* | | | | | | | | Merge #8561bors[bot]2021-04-182-5/+23
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8561: Accept `E<error_number>` notation in doctests r=Veykril a=ChayimFriedman2 ```` ```compile_fail,E0000 ``` ```` The code was stolen from rustdoc at https://github.com/rust-lang/rust/blob/392ba2ba1a7d6c542d2459fb8133bebf62a4a423/src/librustdoc/html/markdown.rs#L866-L867 Co-authored-by: Chayim Refael Friedman <[email protected]>
| * | | | | | | | | Accept `E<error_number>` notation in doctestsChayim Refael Friedman2021-04-182-5/+23
| |/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ```compile_fail,E0000 ``` The code was stolen from rustdoc at https://github.com/rust-lang/rust/blob/392ba2ba1a7d6c542d2459fb8133bebf62a4a423/src/librustdoc/html/markdown.rs#L866-L867
* | | | | | | | | Merge #8560bors[bot]2021-04-182-3/+23
|\ \ \ \ \ \ \ \ \ | |/ / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8560: Escape characters in doc comments in macros correctly r=jonas-schievink a=ChayimFriedman2 Previously they were escaped twice, both by `.escape_default()` and the debug view of strings (`{:?}`). This leads to things like newlines or tabs in documentation comments being `\\n`, but we unescape literals only once, ending up with `\n`. This was hard to spot because CMark unescaped them (at least for `'` and `"`), but it did not do so in code blocks. This also was the root cause of #7781. This issue was solved by using `.escape_debug()` instead of `.escape_default()`, but the real issue remained. We can bring the `.escape_default()` back by now, however I didn't do it because it is probably slower than `.escape_debug()` (more work to do), and also in order to change the code the least. Example (the keyword and primitive docs are `include!()`d at https://doc.rust-lang.org/src/std/lib.rs.html#570-578, and thus originate from macro): Before: ![image](https://user-images.githubusercontent.com/24700207/115130096-40544300-9ff5-11eb-847b-969e7034e8a4.png) After: ![image](https://user-images.githubusercontent.com/24700207/115130143-9cb76280-9ff5-11eb-9281-323746089440.png) Co-authored-by: Chayim Refael Friedman <[email protected]>
| * | | | | | | | Escape characters in doc comments in macros correctlyChayim Refael Friedman2021-04-182-3/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously they were escaped twice, both by `.escape_default()` and the debug view of strings (`{:?}`). This leads to things like newlines or tabs in documentation comments being `\\n`, but we unescape literals only once, ending up with `\n`. This was hard to spot because CMark unescaped them (at least for `'` and `"`), but it did not do so in code blocks. This also was the root cause of #7781. This issue was solved by using `.escape_debug()` instead of `.escape_default()`, but the real issue remained. We can bring the `.escape_default()` back by now, however I didn't do it because it is probably slower than `.escape_debug()` (more work to do), and also in order to change the code the least.
* | | | | | | | | Merge #8559bors[bot]2021-04-172-4/+6
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8559: Add some more error messages to fixture failure cases r=Veykril a=Veykril Follow up for #8557 bors r+ Co-authored-by: Lukas Wirth <[email protected]>
| * | | | | | | | | Add some more error messages to fixture failure casesLukas Wirth2021-04-172-4/+6
|/ / / / / / / / /
* | | | | | | | | Merge #8557bors[bot]2021-04-171-1/+3
|\ \ \ \ \ \ \ \ \ | |_|_|_|_|/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8557: Add an error message to fixture errors r=Veykril a=yoshuawuyts Improve the error message when folks forget to add an `$0` in one of the fixtures. Figuring this one out was 20 minutes down the drain for me, so figured I might as well make sure nobody else has to go through the same thing in the future. Thanks! Co-authored-by: Yoshua Wuyts <[email protected]>
| * | | | | | | | Add an error message to fixture errorsYoshua Wuyts2021-04-171-1/+3
|/ / / / / / / /
* | | | | | | | Merge #8551bors[bot]2021-04-171-1/+1
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8551: nail rowan version down r=lnicola a=drahnr The different pre versions include breaking changes, which cause build failures for the users. Co-authored-by: Bernhard Schuster <[email protected]>
| * | | | | | | | 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
|/ / / / / /