aboutsummaryrefslogtreecommitdiff
path: root/crates/server/src/main_loop
diff options
context:
space:
mode:
Diffstat (limited to 'crates/server/src/main_loop')
-rw-r--r--crates/server/src/main_loop/handlers.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/crates/server/src/main_loop/handlers.rs b/crates/server/src/main_loop/handlers.rs
index d4ae2a368..14dcafc38 100644
--- a/crates/server/src/main_loop/handlers.rs
+++ b/crates/server/src/main_loop/handlers.rs
@@ -50,9 +50,10 @@ pub fn handle_document_symbol(
50 let mut res: Vec<DocumentSymbol> = Vec::new(); 50 let mut res: Vec<DocumentSymbol> = Vec::new();
51 51
52 for symbol in libeditor::file_symbols(&file) { 52 for symbol in libeditor::file_symbols(&file) {
53 let name = symbol.name.to_string();
53 let doc_symbol = DocumentSymbol { 54 let doc_symbol = DocumentSymbol {
54 name: symbol.name.clone(), 55 name: name.clone(),
55 detail: Some(symbol.name), 56 detail: Some(name),
56 kind: symbol.kind.conv(), 57 kind: symbol.kind.conv(),
57 deprecated: None, 58 deprecated: None,
58 range: symbol.node_range.conv_with(&line_index), 59 range: symbol.node_range.conv_with(&line_index),