]> git.ipfire.org Git - thirdparty/vim.git/commit
patch 9.1.1259: some issues with comment package and tailing spaces v9.1.1259
authorMaxim Kim <habamax@gmail.com>
Sun, 30 Mar 2025 12:55:26 +0000 (14:55 +0200)
committerChristian Brabandt <cb@256bit.org>
Sun, 30 Mar 2025 12:55:26 +0000 (14:55 +0200)
commita580761a452a3c4aea8af6d7efb1edc373d303b4
tree1e8cfba01c554824a6787daeaf5c0b6b28aaf390
parentbb8e5ddb970a6739a25746ea195a9c37e4fefd01
patch 9.1.1259: some issues with comment package and tailing spaces

Problem:  some issues with comment package and tailing spaces
Solution: correctly capture trailing spaces with the ac/ic text object
          (Maxim Kim)

This commit fixes a few issues with the comment package:

1) both ac and ic incorrectly miss the last //

```
// hello trailing spaces
//
```

2) fix ac/ic with last empty comment line,
   vac should also select last line with #

```py
 # print("hello")
 # print("world")
 #
 #
$endofbuffer$
```

closes: #17013

Signed-off-by: Maxim Kim <habamax@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
runtime/pack/dist/opt/comment/autoload/comment.vim
src/testdir/test_plugin_comment.vim
src/version.c