From ed2ac1713326df6b926062efcc6109a20cdf7c37 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Mon, 13 Aug 2018 14:24:22 +0300 Subject: smol_str to a crate --- crates/server/src/main_loop/handlers.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'crates/server/src') 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( let mut res: Vec = Vec::new(); for symbol in libeditor::file_symbols(&file) { + let name = symbol.name.to_string(); let doc_symbol = DocumentSymbol { - name: symbol.name.clone(), - detail: Some(symbol.name), + name: name.clone(), + detail: Some(name), kind: symbol.kind.conv(), deprecated: None, range: symbol.node_range.conv_with(&line_index), -- cgit v1.2.3