mirror of
https://github.com/ilyakooo0/helix.git
synced 2024-12-01 19:58:12 +03:00
Fix deleting word from end of buffer (#4328)
This commit is contained in:
parent
0c14d9f869
commit
1a772d1b67
@ -2885,7 +2885,7 @@ pub mod insert {
|
||||
|
||||
/// Exclude the cursor in range.
|
||||
fn exclude_cursor(text: RopeSlice, range: Range, cursor: Range) -> Range {
|
||||
if range.to() == cursor.to() {
|
||||
if range.to() == cursor.to() && text.len_chars() != cursor.to() {
|
||||
Range::new(
|
||||
range.from(),
|
||||
graphemes::prev_grapheme_boundary(text, cursor.to()),
|
||||
|
Loading…
Reference in New Issue
Block a user