Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

Actually display the correct completion's doc

Julia1584dae9c211
diff --git a/crates/editor/src/editor.rs b/crates/editor/src/editor.rs
index b1c5e35703c..ba2b50c1c1e 100644
--- a/crates/editor/src/editor.rs
+++ b/crates/editor/src/editor.rs
@@ -1050,7 +1050,8 @@ impl CompletionsMenu {
Flex::row()
.with_child(list)
.with_children({
- let completion = &self.completions[selected_item];
+ let mat = &self.matches[selected_item];
+ let completion = &self.completions[mat.candidate_id];
let documentation = &completion.lsp_completion.documentation;
if let Some(lsp::Documentation::MarkupContent(content)) = documentation {