diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-05-03 05:56:59 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2020-05-03 05:56:59 +0100 |
commit | 2474f42ae95bffea7c0bc713f92322bfec4d59a7 (patch) | |
tree | aa7eb8f934a1ce4bcd32bd106fbbd2adafef023f /crates/ra_syntax/src | |
parent | 17bd79f4978f1bf7267b54f86d676eed44af02d0 (diff) | |
parent | 2fd054f276e6fd75237b476622d03eef2f18430a (diff) |
Merge #4270
4270: Improve derive macro completion r=edwin0cheng a=SomeoneToIgnore
* Adds completions for standard derive macros (considering their dependencies on each other, so we don't get compile errors)
* Adds completions for custom derive macros that are in scope, if the proc macro feature is enabled in the settings
* Separates macro completion from other completions to avoid incorrect completion propositions
Co-authored-by: Kirill Bulatov <[email protected]>
Diffstat (limited to 'crates/ra_syntax/src')
-rw-r--r-- | crates/ra_syntax/src/ast/extensions.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_syntax/src/ast/extensions.rs b/crates/ra_syntax/src/ast/extensions.rs index 528c873e0..98c38d009 100644 --- a/crates/ra_syntax/src/ast/extensions.rs +++ b/crates/ra_syntax/src/ast/extensions.rs | |||
@@ -467,7 +467,7 @@ impl ast::TokenTree { | |||
467 | 467 | ||
468 | pub fn right_delimiter_token(&self) -> Option<SyntaxToken> { | 468 | pub fn right_delimiter_token(&self) -> Option<SyntaxToken> { |
469 | self.syntax().last_child_or_token()?.into_token().filter(|it| match it.kind() { | 469 | self.syntax().last_child_or_token()?.into_token().filter(|it| match it.kind() { |
470 | T!['{'] | T!['('] | T!['['] => true, | 470 | T!['}'] | T![')'] | T![']'] => true, |
471 | _ => false, | 471 | _ => false, |
472 | }) | 472 | }) |
473 | } | 473 | } |