@@ -125,6 +125,10 @@ pub fn move_line_start(cx: &mut Context) {
125125 doc.set_selection(selection);
126126}
127127
128+// TODO: move vs extend could take an extra type Extend/Move that would
129+// Range::new(if Move { pos } if Extend { range.anchor }, pos)
130+// since these all really do the same thing
131+
128132pub fn move_next_word_start(cx: &mut Context) {
129133 let count = cx.count;
130134 let doc = cx.doc();
@@ -958,9 +962,7 @@ pub fn format_selections(cx: &mut Context) {
958962 .selection()
959963 .ranges()
960964 .iter()
961− .map(|range| {
962− helix_lsp::util::range_to_lsp_range(doc.text().slice(..), doc.selection().primary())
963− })
965+ .map(|range| helix_lsp::util::range_to_lsp_range(doc.text().slice(..), *range))
964966 .collect();
965967
966968 for range in ranges {