]>
git.lizzy.rs Git - rust.git/log
bors [Wed, 27 Apr 2022 12:32:35 +0000 (12:32 +0000)]
Auto merge of #12097 - lnicola:revert-11490, r=lnicola
Revert #11490
Closes #11725
#11490 was a little misguided. Quoting the test name should be a client concern, since it's the client that actually runs `cargo`.
Laurențiu Nicola [Wed, 27 Apr 2022 12:27:50 +0000 (15:27 +0300)]
Revert "Correctly fix formatting doc tests with generics"
This reverts commit
5f3327a6b8925791ecdd9dbecb1bf1537c3ef9fc .
Laurențiu Nicola [Wed, 27 Apr 2022 12:27:48 +0000 (15:27 +0300)]
Revert "Update crates/ide/src/runnables.rs"
This reverts commit
bf47acf1d3451eb281ea56a6ad8f5e1834ce6a8f .
bors [Wed, 27 Apr 2022 10:43:43 +0000 (10:43 +0000)]
Auto merge of #12085 - rainy-me:fix_fn_param, r=Veykril
fix: fn_param completion lookup
close #12073 caused by #12040
rainy-me [Wed, 27 Apr 2022 09:54:57 +0000 (18:54 +0900)]
fix: remove lookup and handle mut kw case
bors [Tue, 26 Apr 2022 09:53:26 +0000 (09:53 +0000)]
Auto merge of #12083 - Veykril:inlays, r=Veykril
minor: Add test for parameter and reborrow hint order
Lukas Wirth [Tue, 26 Apr 2022 09:46:03 +0000 (11:46 +0200)]
minor: Add test for parameter and reborrow hint order
bors [Tue, 26 Apr 2022 07:34:00 +0000 (07:34 +0000)]
Auto merge of #12082 - iDawer:ide.signature_help, r=lnicola
fix: `signature_help`: use corresponding param list for methods
Close #12079
iDawer [Tue, 26 Apr 2022 06:50:28 +0000 (11:50 +0500)]
`signature_help`: use corresponding param list for methods
bors [Mon, 25 Apr 2022 17:01:44 +0000 (17:01 +0000)]
Auto merge of #12078 - Veykril:neither, r=Veykril
minor: Re-export `FxHashMap` and `FxHashSet` from `ide_db`
Lukas Wirth [Mon, 25 Apr 2022 16:51:59 +0000 (18:51 +0200)]
Re-export `FxHashMap` and `FxHashSet` from `ide_db`
bors [Mon, 25 Apr 2022 16:48:42 +0000 (16:48 +0000)]
Auto merge of #12077 - Veykril:neither, r=Veykril
minor: Remove `either` dependency from `ide_completion`
bors r+
Lukas Wirth [Mon, 25 Apr 2022 16:40:38 +0000 (18:40 +0200)]
minor: Remove either dependency from `ide_completion`
bors [Mon, 25 Apr 2022 13:22:41 +0000 (13:22 +0000)]
Auto merge of #12075 - jonas-schievink:less-aggressive-quickfixes, r=jonas-schievink
fix: Don't emit a quickfix for placeholder suggestions from rustc/clippy
Fixes https://github.com/rust-lang/rust-analyzer/issues/12069
Jonas Schievink [Mon, 25 Apr 2022 13:21:30 +0000 (15:21 +0200)]
Don't emit a quickfix for placeholder suggestions
bors [Mon, 25 Apr 2022 12:56:57 +0000 (12:56 +0000)]
Auto merge of #12007 - edwin0cheng:restart-proc-macro-reload, r=jonas-schievink
Restart proc-macro client when server reload
Fix #10719
bors [Mon, 25 Apr 2022 12:44:49 +0000 (12:44 +0000)]
Auto merge of #12071 - Ma124:fix-tabs-snippet, r=jonas-schievink
Change tabs to spacs in macro_rules snippet
This PR changes the `macro_rules!` snippet to use spaces instead of tabs.
The other snippets like [this one][test-snippet] already use spaces.
The snippet was introduced in
5575588 where no reason is provided to use tabs.
[test-snippet]: https://github.com/rust-lang/rust-analyzer/blob/master/crates/ide_completion/src/completions/snippet.rs#L70=
bors [Mon, 25 Apr 2022 12:35:39 +0000 (12:35 +0000)]
Auto merge of #12074 - jonas-schievink:deprioritize-flyimport, r=jonas-schievink
Reduce priority of flyimport completions
Fixes https://github.com/rust-lang/rust-analyzer/issues/12068
Jonas Schievink [Mon, 25 Apr 2022 12:34:54 +0000 (14:34 +0200)]
Reduce priority of flyimport completions
bors [Mon, 25 Apr 2022 11:07:09 +0000 (11:07 +0000)]
Auto merge of #12072 - bitgaoshu:master, r=jonas-schievink
fix #11973 associated type is unresolved
Ma_124 [Sun, 24 Apr 2022 12:24:59 +0000 (14:24 +0200)]
Change tabs to spacs in macro_rules snippet
bitgaoshu [Sun, 24 Apr 2022 12:51:48 +0000 (20:51 +0800)]
#11973 associated type is unresolved
bors [Sun, 24 Apr 2022 12:41:16 +0000 (12:41 +0000)]
Auto merge of #12070 - rust-lang:message, r=matklad
minor: clarify error message
Clarify that the server is a whole is OK, and that it's only a single
requests that's dead
Aleksey Kladov [Sun, 24 Apr 2022 12:39:33 +0000 (13:39 +0100)]
minor: clarify error message
Clarify that the server is a whole is OK, and that it's only a single
requests that's dead
Edwin Cheng [Sun, 24 Apr 2022 03:59:08 +0000 (11:59 +0800)]
Fix Reload Workspace command
bors [Sat, 23 Apr 2022 14:37:35 +0000 (14:37 +0000)]
Auto merge of #12064 - Veykril:attr-range, r=Veykril
fix: Fix `ide_db::search` not searching bodies of attributed items
Fixes https://github.com/rust-lang/rust-analyzer/issues/12050
Lukas Wirth [Sat, 23 Apr 2022 14:36:11 +0000 (16:36 +0200)]
fix: Fix ide_db::search not searching bodies of attributed items
bors [Sat, 23 Apr 2022 14:23:30 +0000 (14:23 +0000)]
Auto merge of #12063 - iDawer:ide.signature_help, r=Veykril
fix: Fall back to parameter definitions on error types in signature help
Fixes #10432
iDawer [Sat, 23 Apr 2022 11:45:47 +0000 (16:45 +0500)]
Add fallback for return type
iDawer [Sat, 23 Apr 2022 10:10:10 +0000 (15:10 +0500)]
Fall back to parameter definitions on error types in signature help
bors [Sat, 23 Apr 2022 00:29:18 +0000 (00:29 +0000)]
Auto merge of #12060 - Veykril:completion-ctx, r=Veykril
minor: Simplify
bors r+
Lukas Wirth [Sat, 23 Apr 2022 00:21:27 +0000 (02:21 +0200)]
Simplify
bors [Fri, 22 Apr 2022 15:46:30 +0000 (15:46 +0000)]
Auto merge of #12058 - jonas-schievink:one-thread-with-extra-stack-please, r=jonas-schievink
fix: Spawn a new thread with a larger stack for the LSP and proc-macro server
This runs the server and proc-macro process in dedicated threads with 8 MB of stack space to paper over OS differences and fix occasional stack overflows.
This hopefully resolves https://github.com/rust-lang/rust-analyzer/issues/11669
Jonas Schievink [Fri, 22 Apr 2022 15:30:18 +0000 (17:30 +0200)]
Spawn a new thread with a larger stack for the server
bors [Fri, 22 Apr 2022 15:22:49 +0000 (15:22 +0000)]
Auto merge of #12054 - HKalbasi:const_generic, r=flodiebold
Fix const generic panic in dyn trait
fix #12048
hkalbasi [Fri, 22 Apr 2022 14:59:10 +0000 (19:29 +0430)]
remove trailing space
hkalbasi [Fri, 22 Apr 2022 14:52:18 +0000 (19:22 +0430)]
Add some comments about why never!() never happens
bors [Fri, 22 Apr 2022 14:42:25 +0000 (14:42 +0000)]
Auto merge of #12053 - willcrichton:master, r=jonas-schievink
Export lc.LanguageClient from VSCode extension
As described in [this Zulip thread](https://rust-lang.zulipchat.com/#narrow/stream/185405-t-compiler.2Frust-analyzer/topic/Use.20Rust.20Analyzer.20in.20another.20VSCode.20extension), I would like to experiment with using Rust Analyzer's language server inside another VSCode extension, [Flowistry](https://github.com/willcrichton/flowistry). My current use case is to use one of Rust Analyzer's assists (extract function).
This PR would enable that experimentation by exporting the `lc.LanguageClient` from the `activate` function, which [allows other extensions to access it](https://code.visualstudio.com/api/references/vscode-api#extensions). This PR does **not** commit RA to any stability guarantees about the language client, similar to how rustc exports an unstable API.
hkalbasi [Thu, 21 Apr 2022 21:05:28 +0000 (01:35 +0430)]
fix const generic panic in dyn trait
Will Crichton [Thu, 21 Apr 2022 20:39:53 +0000 (13:39 -0700)]
Export lc.LanguageClient from VSCode extension
bors [Thu, 21 Apr 2022 18:10:37 +0000 (18:10 +0000)]
Auto merge of #12052 - lnicola:cargo-config, r=lnicola
minor: drop `install-ra` cargo alias
Laurențiu Nicola [Thu, 21 Apr 2022 18:08:07 +0000 (21:08 +0300)]
Rename cargo config to config.toml
Laurențiu Nicola [Thu, 21 Apr 2022 18:06:28 +0000 (21:06 +0300)]
Remove old install-ra cargo alias
bors [Thu, 21 Apr 2022 16:52:10 +0000 (16:52 +0000)]
Auto merge of #12015 - arjo129:master, r=jonas-schievink
[Documentation]: Update developer documentation link.
Just noticed the docs links broken. The current doc link was broken. replaced with the updated version as found on the front page. Should the rest of the links be updated?
bors [Thu, 21 Apr 2022 15:48:42 +0000 (15:48 +0000)]
Auto merge of #12051 - jonas-schievink:triagebot, r=jonas-schievink
Add triagebot.toml
Allow people to claim issues
Jonas Schievink [Thu, 21 Apr 2022 15:43:12 +0000 (17:43 +0200)]
Add triagebot.toml
bors [Thu, 21 Apr 2022 15:39:10 +0000 (15:39 +0000)]
Auto merge of #12040 - rainy-me:improve-parameter-completion, r=jonas-schievink
fix: Improve parameter completion
fix https://github.com/rust-lang/rust-analyzer/issues/12016 and handles some extra cases.
rainy-me [Thu, 21 Apr 2022 15:07:42 +0000 (00:07 +0900)]
fix: lookup
bors [Thu, 21 Apr 2022 14:03:37 +0000 (14:03 +0000)]
Auto merge of #12044 - tedinski:fix_rustc_workspace, r=jonas-schievink
fix: index the correct CargoWorkspace with rustc_private
I believe this fixes #12043, but I'm not sufficiently setup/familiar with working on rust-analyzer to test it locally. :/
This section of code is iterating on `rustc_workspace.packages()` but then indexes `cargo[pkg]`, which is likely the source of the bug.
Ted Kaminski [Wed, 20 Apr 2022 17:16:04 +0000 (17:16 +0000)]
fix: index the correct CargoWorkspace with rustc_private
bors [Wed, 20 Apr 2022 14:54:24 +0000 (14:54 +0000)]
Auto merge of #12042 - jonas-schievink:remove-angle-brackets-from-lang-config, r=jonas-schievink
fix: remove angle brackets from language configuration
This should fix https://github.com/rust-lang/rust-analyzer/issues/12034
It looks like we shouldn't add any characters here that can be ambiguous, because it can make the editor highlight unrelated characters. This needs a parser to be correct, so the language server is the right place, not the editor. Upstream LSP feature request: https://github.com/microsoft/language-server-protocol/issues/672 (but it might be possible to implement this as an extension today, as long as that doesn't conflict with the built-in highlighting).
Jonas Schievink [Wed, 20 Apr 2022 14:43:24 +0000 (16:43 +0200)]
fix: remove angle brackets from language configuration
bors [Wed, 20 Apr 2022 12:11:09 +0000 (12:11 +0000)]
Auto merge of #12041 - jonas-schievink:prefer-core-cfg-attr-no-std, r=jonas-schievink
feat: prefer core/alloc over std in auto-imports if `#[no_std]` is conditional
We already did this if `#![no_std]` was present, this PR makes it work with `#![cfg_attr(not(test), no_std)]` too, which is very common in libraries.
Fixes https://github.com/rust-lang/rust-analyzer/issues/12035
cc https://github.com/rust-lang/rust-analyzer/issues/10718
Jonas Schievink [Wed, 20 Apr 2022 12:07:40 +0000 (14:07 +0200)]
Prefer core/alloc over std if no_std is conditional
rainy-me [Wed, 20 Apr 2022 08:56:20 +0000 (17:56 +0900)]
fix: improve parameter completion
bors [Wed, 20 Apr 2022 04:38:22 +0000 (04:38 +0000)]
Auto merge of #12037 - lnicola:inlay-hint-config, r=lnicola
fix: Remove `rust-analyzer.inlayHints.enable` and set language scope
Closes #12036
CC https://github.com/rust-lang/rust-analyzer/issues/12027#issuecomment-
1102990324
The key was left there by mistake in #12006.
Setting the configuration scope only works if you already have it created, which is fine, but unfortunately not quite discoverable.
Laurențiu Nicola [Wed, 20 Apr 2022 04:34:00 +0000 (07:34 +0300)]
Pass the language id when toggling inlay hints
Laurențiu Nicola [Wed, 20 Apr 2022 04:33:26 +0000 (07:33 +0300)]
Actually remove rust-analyzer.inlayHints.enable
bors [Tue, 19 Apr 2022 16:46:33 +0000 (16:46 +0000)]
Auto merge of #12032 - jonas-schievink:code-action-commands, r=jonas-schievink
feat: display signature help when applying "Add `::<>`" assist
Closes https://github.com/rust-lang/rust-analyzer/issues/12031
Jonas Schievink [Tue, 19 Apr 2022 16:37:18 +0000 (18:37 +0200)]
Allows triggering commands after an assist edit
bors [Tue, 19 Apr 2022 07:57:12 +0000 (07:57 +0000)]
Auto merge of #12029 - xuhongxu96:master, r=lnicola
Fix typo "GreeNode" in syntax.md
Hongxu Xu [Tue, 19 Apr 2022 07:45:03 +0000 (15:45 +0800)]
Fix typo "GreeNode" in syntax.md
bors [Tue, 19 Apr 2022 06:09:32 +0000 (06:09 +0000)]
Auto merge of #12028 - lnicola:fix-changelog, r=lnicola
internal: Fix changelog generation after repo move
Laurențiu Nicola [Tue, 19 Apr 2022 06:07:10 +0000 (09:07 +0300)]
Fix changelog generation after repo move
bors [Mon, 18 Apr 2022 14:55:31 +0000 (14:55 +0000)]
Auto merge of #12025 - Veykril:completion-ctx, r=Veykril
minor: Document completion context some more
Lukas Wirth [Mon, 18 Apr 2022 14:54:13 +0000 (16:54 +0200)]
minor: Document completion context some more
bors [Mon, 18 Apr 2022 14:00:56 +0000 (14:00 +0000)]
Auto merge of #12021 - Veykril:completion-ctx, r=Veykril
internal: Add a `NameContext` to `CompletionContext`, move out some ImmediateLocation variants
Continues the completion rewrite I started some time ago
(will merge tomorrow after stable since our completion tests still let a lot through)
bors [Mon, 18 Apr 2022 13:40:18 +0000 (13:40 +0000)]
Auto merge of #12024 - XFFXFF:derive_completion, r=Veykril
derive completions take existing derives into count
fixes #12019
The immediate reason is that when we are doing derive completion, [`ctx.existing_derives`](https://github.com/rust-lang/rust-analyzer/blob/
d1f6b4e2a0ab1a1343ab4a381c89b186a76fd001 /crates/ide_completion/src/completions/attribute/derive.rs#L82) is empty, this is because we expand the macro when looking for the ancestors of the token to be completed. Take the following code as an example, we find the first `SyntaxNode` with kind `Attr` based on the ancestors of the token, but the parent of `Attr` is not a `Struct` as we [expect](https://github.com/rust-lang/rust-analyzer/blob/
d1f6b4e2a0ab1a1343ab4a381c89b186a76fd001 /crates/hir/src/semantics.rs#L518).
```rust
#[derive(PartialEq, Eq, Or$0)]
struct S;
```
The ancestors of the token to be completed above.
```
NAME_REF@24..26
IDENT@24..26 "Or"
,
PATH_SEGMENT@24..26
NAME_REF@24..26
IDENT@24..26 "Or"
,
PATH@24..26
PATH_SEGMENT@24..26
NAME_REF@24..26
IDENT@24..26 "Or"
,
META@24..26
PATH@24..26
PATH_SEGMENT@24..26
NAME_REF@24..26
IDENT@24..26 "Or"
,
ATTR@21..28
POUND@21..22 "#"
WHITESPACE@22..23 " "
L_BRACK@23..24 "["
META@24..26
PATH@24..26
PATH_SEGMENT@24..26
NAME_REF@24..26
IDENT@24..26 "Or"
R_BRACK@26..27 "]"
WHITESPACE@27..28 " "
,
TUPLE_EXPR@0..32
ATTR@0..14
POUND@0..1 "#"
WHITESPACE@1..2 " "
L_BRACK@2..3 "["
META@3..12
PATH@3..12
PATH_SEGMENT@3..12
NAME_REF@3..12
IDENT@3..12 "PartialEq"
R_BRACK@12..13 "]"
WHITESPACE@13..14 " "
ATTR@14..21
POUND@14..15 "#"
WHITESPACE@15..16 " "
L_BRACK@16..17 "["
META@17..19
PATH@17..19
PATH_SEGMENT@17..19
NAME_REF@17..19
IDENT@17..19 "Eq"
R_BRACK@19..20 "]"
WHITESPACE@20..21 " "
ATTR@21..28
POUND@21..22 "#"
WHITESPACE@22..23 " "
L_BRACK@23..24 "["
META@24..26
PATH@24..26
PATH_SEGMENT@24..26
NAME_REF@24..26
IDENT@24..26 "Or"
R_BRACK@26..27 "]"
WHITESPACE@27..28 " "
L_PAREN@28..29 "("
WHITESPACE@29..30 " "
R_PAREN@30..31 ")"
WHITESPACE@31..32 " "
...
```
I make a small change to not do macro expansion when looking up the ancestors of the token.
What I don't understand is that `self.sema.token_ancestors_with_macros(self.token.clone())` doesn't seem to expand the macro if the derive completion triggered without any prefix, like `#[derive(PartialEq, Eq, $0)]`.
The ancestors of the token with `#[derive(PartialEq, Eq, $0)]`.
```
TOKEN_TREE@8..25
L_PAREN@8..9 "("
IDENT@9..18 "PartialEq"
COMMA@18..19 ","
WHITESPACE@19..20 " "
IDENT@20..22 "Eq"
COMMA@22..23 ","
WHITESPACE@23..24 " "
R_PAREN@24..25 ")"
,
META@2..25
PATH@2..8
PATH_SEGMENT@2..8
NAME_REF@2..8
IDENT@2..8 "derive"
TOKEN_TREE@8..25
L_PAREN@8..9 "("
IDENT@9..18 "PartialEq"
COMMA@18..19 ","
WHITESPACE@19..20 " "
IDENT@20..22 "Eq"
COMMA@22..23 ","
WHITESPACE@23..24 " "
R_PAREN@24..25 ")"
,
ATTR@0..26
POUND@0..1 "#"
L_BRACK@1..2 "["
META@2..25
PATH@2..8
PATH_SEGMENT@2..8
NAME_REF@2..8
IDENT@2..8 "derive"
TOKEN_TREE@8..25
L_PAREN@8..9 "("
IDENT@9..18 "PartialEq"
COMMA@18..19 ","
WHITESPACE@19..20 " "
IDENT@20..22 "Eq"
COMMA@22..23 ","
WHITESPACE@23..24 " "
R_PAREN@24..25 ")"
R_BRACK@25..26 "]"
,
STRUCT@0..39
ATTR@0..26
POUND@0..1 "#"
L_BRACK@1..2 "["
META@2..25
PATH@2..8
PATH_SEGMENT@2..8
NAME_REF@2..8
IDENT@2..8 "derive"
TOKEN_TREE@8..25
L_PAREN@8..9 "("
IDENT@9..18 "PartialEq"
COMMA@18..19 ","
WHITESPACE@19..20 " "
IDENT@20..22 "Eq"
COMMA@22..23 ","
WHITESPACE@23..24 " "
R_PAREN@24..25 ")"
R_BRACK@25..26 "]"
WHITESPACE@26..27 " "
STRUCT_KW@27..33 "struct"
WHITESPACE@33..34 " "
NAME@34..38
IDENT@34..38 "Test"
SEMICOLON@38..39 ";"
...
```
XFFXFF [Mon, 18 Apr 2022 13:34:36 +0000 (21:34 +0800)]
derive completions take existing derives into count
bors [Mon, 18 Apr 2022 07:13:30 +0000 (07:13 +0000)]
Auto merge of #12023 - edwin0cheng:add-more-log, r=edwin0cheng
internal: more visibility for switch workspaces and its states
Edwin Cheng [Mon, 18 Apr 2022 06:26:00 +0000 (14:26 +0800)]
More visibility for switch workspaces and its states
Lukas Wirth [Sun, 17 Apr 2022 19:53:58 +0000 (21:53 +0200)]
internal: Add a `NameContext` to `CompletionContext`, move out some ImmediateLocation variants
bors [Sun, 17 Apr 2022 16:36:36 +0000 (16:36 +0000)]
Auto merge of #12017 - lnicola:bump-deps, r=lnicola
minor: Bump deps
Laurențiu Nicola [Sun, 17 Apr 2022 16:36:08 +0000 (19:36 +0300)]
Bump deps
bors [Sun, 17 Apr 2022 13:05:47 +0000 (13:05 +0000)]
Auto merge of #12013 - XFFXFF:associated_const_equality, r=Veykril
fix: support `associated_const_equality` in parser
This pr fixes #11965. The parser now allows eq constraints on associated constants.
I've added tests for `HasCount<Count = {N}>` and `HasCount<Count = 0>`
Arjo Chakravarty [Sun, 17 Apr 2022 12:32:06 +0000 (20:32 +0800)]
Update docs link
The current doc link was broken. replaced with the updated version as found on the front page.
XFFXFF [Sun, 17 Apr 2022 12:26:06 +0000 (20:26 +0800)]
update parser to support associated const equality
bors [Sun, 17 Apr 2022 12:03:27 +0000 (12:03 +0000)]
Auto merge of #12014 - Veykril:expmacfmt, r=Veykril
feat: Attempt to format expand_macro output with rustfmt if possible
Fixes https://github.com/rust-lang/rust-analyzer/issues/10548
Lukas Wirth [Sun, 17 Apr 2022 12:00:19 +0000 (14:00 +0200)]
Disable rustfmt for expand_macro on wasm platforms
Lukas Wirth [Sun, 17 Apr 2022 11:46:00 +0000 (13:46 +0200)]
Fix macro patterns not getting formatted properly
Lukas Wirth [Sun, 17 Apr 2022 11:33:39 +0000 (13:33 +0200)]
feat: Attempt to format expand_macro output with rustfmt if possible
XFFXFF [Sun, 17 Apr 2022 04:03:52 +0000 (12:03 +0800)]
update grammer to support associated const equality
bors [Sat, 16 Apr 2022 21:13:07 +0000 (21:13 +0000)]
Auto merge of #12011 - iDawer:completion_detail.impl_trait, r=Veykril
fix: Show `impl Trait` in argument positon in completion details
Follow up for #11991
`hir`: Use `db.callable_item_signature` query more.
iDawer [Sat, 16 Apr 2022 14:18:42 +0000 (19:18 +0500)]
Show `impl Trait` in argument positon in completion details
`hir`: Use `db.callable_item_signature` query more.
bors [Sat, 16 Apr 2022 12:18:00 +0000 (12:18 +0000)]
Auto merge of #12009 - matklad:debug-reloads, r=matklad
internal: more visibility into why things happen
Aleksey Kladov [Sat, 16 Apr 2022 12:16:58 +0000 (13:16 +0100)]
internal: more visibility into why things happen
bors [Sat, 16 Apr 2022 10:37:28 +0000 (10:37 +0000)]
Auto merge of #12008 - Veykril:patch-1, r=Veykril
fix: Fix proc-macro change check being inverted
Lukas Wirth [Sat, 16 Apr 2022 10:36:31 +0000 (12:36 +0200)]
fix: Fix proc-macro change check being inverted
bors [Sat, 16 Apr 2022 09:26:09 +0000 (09:26 +0000)]
Auto merge of #11991 - iDawer:completion_detail.impl_trait, r=iDawer
fix: completion detail shows `{unknown}` for async functions and for RPITs
Fix: completion detail shows `{unknown}` for `impl Trait` in return position.
Fix #11438 : completion detail shows `{unknown}` for return types in async functions.
#### API changes
Add `hir::Function::async_ret_type` method
iDawer [Thu, 14 Apr 2022 16:16:25 +0000 (21:16 +0500)]
minor: address nit
iDawer [Thu, 14 Apr 2022 16:12:26 +0000 (21:12 +0500)]
`extract_function`: use appropriate return type for async fns
iDawer [Thu, 14 Apr 2022 12:44:17 +0000 (17:44 +0500)]
Add `hir::Function::async_ret_type` method
Adjust completion detail for `async fn` return types
iDawer [Tue, 12 Apr 2022 15:40:31 +0000 (20:40 +0500)]
fix: comletion detail shows `{unknown}` for `impl Trait` in return position
bors [Sat, 16 Apr 2022 05:10:17 +0000 (05:10 +0000)]
Auto merge of #12006 - lnicola:toggle-inlay-hints, r=lnicola
fix: Remove old inlay hints settings
Closes #11998
Laurențiu Nicola [Sat, 16 Apr 2022 05:04:52 +0000 (08:04 +0300)]
Remove old inlay hints settings
bors [Fri, 15 Apr 2022 20:23:15 +0000 (20:23 +0000)]
Auto merge of #12005 - Veykril:hir-ty-simplify, r=Veykril
internal: Remove frequent `Arc<Body>` clones in type checking
bors r+
Lukas Wirth [Fri, 15 Apr 2022 19:44:47 +0000 (21:44 +0200)]
minor: Remove frequent `Arc<Body>` clones in type checking
Lukas Wirth [Fri, 15 Apr 2022 19:25:44 +0000 (21:25 +0200)]
Simplify
bors [Fri, 15 Apr 2022 18:25:02 +0000 (18:25 +0000)]
Auto merge of #12003 - Veykril:hir-ty-simplify, r=Veykril
internal: Remove duplicated crate id field from hir::Type
Lukas Wirth [Fri, 15 Apr 2022 18:17:50 +0000 (20:17 +0200)]
Slightly optimize `Resolver::krate`