diff options
author | Geert-Jan Zwiers <geertjanzwiers@protonmail.com> | 2023-01-26 23:24:03 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-26 23:24:03 +0100 |
commit | 7f38f30a5c0eb06c5b85d1c7ac26a480c210aab6 (patch) | |
tree | 805c717b5aaf7124a09a3f19f6d2c2d459d2d959 /cli/lsp/completions.rs | |
parent | 21065797f6dce285e55705007f54abe2bafb611c (diff) |
refactor(lsp): fewer clones (#17551)
Diffstat (limited to 'cli/lsp/completions.rs')
-rw-r--r-- | cli/lsp/completions.rs | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/cli/lsp/completions.rs b/cli/lsp/completions.rs index 70d707bc7..a8e7896c5 100644 --- a/cli/lsp/completions.rs +++ b/cli/lsp/completions.rs @@ -324,7 +324,7 @@ fn get_import_map_completions( new_text: label.clone(), })); items.push(lsp::CompletionItem { - label: label.clone(), + label, kind, detail: Some("(import map)".to_string()), sort_text: Some("1".to_string()), @@ -523,12 +523,7 @@ mod tests { for (specifier, source, version, language_id) in fixtures { let specifier = resolve_url(specifier).expect("failed to create specifier"); - documents.open( - specifier.clone(), - *version, - *language_id, - (*source).into(), - ); + documents.open(specifier, *version, *language_id, (*source).into()); } let http_cache = HttpCache::new(location); for (specifier, source) in source_fixtures { |