From 89d1b97187db6453202aee1080f9471e91263c6c Mon Sep 17 00:00:00 2001 From: Kelly Wilson Date: Sat, 21 Sep 2024 11:17:32 -0600 Subject: [PATCH] Fix w command moving to next line when encountering underscore --- src/view.v | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/view.v b/src/view.v index b24790d..d0d866b 100644 --- a/src/view.v +++ b/src/view.v @@ -1987,6 +1987,11 @@ enum PositionWithinWord as u8 { } fn is_special(r rune) ?rune { + // We have to check for the underscore here because is_non_alpha includes + // underscores for large number digit separation! + if r == `_` { + return r + } if !is_whitespace(r) && is_non_alpha(r) && !(r == `\n` || r == `\r`) { return r }