mirror of
https://github.com/neovim/neovim.git
synced 2026-02-20 01:09:56 +10:00
vim-patch:8.2.4805: CurSearch used for all matches in current line
Problem: CurSearch used for all matches in current line.
Solution: Don't use the non-zero line count. (closes vim/vim#10247)
9b36750640
This commit is contained in:
@@ -163,14 +163,14 @@ describe('search highlighting', function()
|
||||
end)
|
||||
|
||||
it('works for multiline match', function()
|
||||
command([[call setline(1, ['one', 'foo', 'bar', 'baz', 'foo', 'bar'])]])
|
||||
command([[call setline(1, ['one', 'foo', 'bar', 'baz', 'foo the foo and foo', 'bar'])]])
|
||||
feed('gg/foo<CR>')
|
||||
screen:expect([[
|
||||
one |
|
||||
{2:^foo} |
|
||||
bar |
|
||||
baz |
|
||||
{1:foo} |
|
||||
{1:foo} the {1:foo} and {1:foo} |
|
||||
bar |
|
||||
/foo |
|
||||
]])
|
||||
@@ -180,11 +180,32 @@ describe('search highlighting', function()
|
||||
{1:foo} |
|
||||
bar |
|
||||
baz |
|
||||
{2:^foo} |
|
||||
{2:^foo} the {1:foo} and {1:foo} |
|
||||
bar |
|
||||
/foo |
|
||||
]])
|
||||
feed('?<CR>')
|
||||
feed('n')
|
||||
screen:expect([[
|
||||
one |
|
||||
{1:foo} |
|
||||
bar |
|
||||
baz |
|
||||
{1:foo} the {2:^foo} and {1:foo} |
|
||||
bar |
|
||||
/foo |
|
||||
]])
|
||||
feed('n')
|
||||
screen:expect([[
|
||||
one |
|
||||
{1:foo} |
|
||||
bar |
|
||||
baz |
|
||||
{1:foo} the {1:foo} and {2:^foo} |
|
||||
bar |
|
||||
/foo |
|
||||
]])
|
||||
command([[call setline(5, 'foo')]])
|
||||
feed('0?<CR>')
|
||||
screen:expect([[
|
||||
one |
|
||||
{2:^foo} |
|
||||
|
||||
Reference in New Issue
Block a user