Fix punctuation movement with one char tokens

Previously, in

    ls ^a bcd

(with "^" as the cursor), kill-word would delete the "a" and then go
on, remove the space and the "bcd".

With this, it will only kill the "a".

Fixes #4747.
This commit is contained in:
Fabian Homborg
2018-02-25 16:30:15 +01:00
parent 2747945c55
commit c793570f2c
2 changed files with 25 additions and 3 deletions

View File

@@ -1993,6 +1993,7 @@ static void test_word_motion() {
test_1_word_motion(word_motion_left, move_word_style_path_components,
L"^echo /^foo/^bar{^aaa,^bbb,^ccc}^bak/");
test_1_word_motion(word_motion_right, move_word_style_punctuation, L"a ^bcd^");
}
/// Test is_potential_path.