From 95dd55ba943f3667bac3acecb2c65ee7f69d42cd Mon Sep 17 00:00:00 2001 From: Blaž Hrastnik Date: Sat, 10 Apr 2021 12:01:49 +0900 Subject: Fix overlap calculation. --- helix-term/src/commands.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'helix-term/src/commands.rs') diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs index b6ae0138..d75cb6ff 100644 --- a/helix-term/src/commands.rs +++ b/helix-term/src/commands.rs @@ -622,7 +622,7 @@ fn _search(doc: &mut Document, view_id: ViewId, contents: &str, regex: &Regex, e let end = text.byte_to_char(mat.end()); let selection = if extend { - selection.clone().add(Range::new(start, end - 1)) + selection.clone().push(Range::new(start, end - 1)) } else { Selection::single(start, end - 1) }; -- cgit v1.2.3-70-g09d2