diff options
author | Edwin Cheng <[email protected]> | 2020-04-18 12:26:35 +0100 |
---|---|---|
committer | Edwin Cheng <[email protected]> | 2020-04-18 12:26:54 +0100 |
commit | f78de3bb95acb996102a74b5b12d33054ba6d4c4 (patch) | |
tree | 3219fe0b36e333c39cb7720ba35ee31046454557 /crates/ra_ide/src/completion | |
parent | 179d9835351f3abab03634b50bcee94723cce148 (diff) |
Ignore proc-macro in completion
Diffstat (limited to 'crates/ra_ide/src/completion')
-rw-r--r-- | crates/ra_ide/src/completion/presentation.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/crates/ra_ide/src/completion/presentation.rs b/crates/ra_ide/src/completion/presentation.rs index 55f75b15a..2189cef65 100644 --- a/crates/ra_ide/src/completion/presentation.rs +++ b/crates/ra_ide/src/completion/presentation.rs | |||
@@ -156,6 +156,12 @@ impl Completions { | |||
156 | name: Option<String>, | 156 | name: Option<String>, |
157 | macro_: hir::MacroDef, | 157 | macro_: hir::MacroDef, |
158 | ) { | 158 | ) { |
159 | // FIXME: Currently proc-macro do not have ast-node, | ||
160 | // such that it does not have source | ||
161 | if macro_.is_proc_macro() { | ||
162 | return; | ||
163 | } | ||
164 | |||
159 | let name = match name { | 165 | let name = match name { |
160 | Some(it) => it, | 166 | Some(it) => it, |
161 | None => return, | 167 | None => return, |