aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
Diffstat (limited to 'crates')
-rw-r--r--crates/rust-analyzer/src/to_proto.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/crates/rust-analyzer/src/to_proto.rs b/crates/rust-analyzer/src/to_proto.rs
index 33c2fd595..2696ecac4 100644
--- a/crates/rust-analyzer/src/to_proto.rs
+++ b/crates/rust-analyzer/src/to_proto.rs
@@ -178,7 +178,9 @@ pub(crate) fn completion_item(
178 }; 178 };
179 179
180 if completion_item.score().is_some() { 180 if completion_item.score().is_some() {
181 res.preselect = Some(true) 181 res.preselect = Some(true);
182 // HACK: sort preselect items first
183 res.sort_text = Some(format!(" {}", completion_item.label()));
182 } 184 }
183 185
184 if completion_item.deprecated() { 186 if completion_item.deprecated() {