mirror of
https://github.com/neovim/neovim.git
synced 2025-10-07 10:26:31 +00:00
vim-patch:8.0.1239: cannot use a lambda for the skip argument to searchpair()
Problem: Cannot use a lambda for the skip argument to searchpair().
Solution: Evaluate a partial, funcref and lambda. (LemonBoy, closes vim/vim#1454,
closes vim/vim#2265)
48570488f1
This commit is contained in:
@@ -3432,7 +3432,7 @@ again:
|
||||
if (do_searchpair((char_u *)
|
||||
"<[^ \t>/!]\\+\\%(\\_s\\_[^>]\\{-}[^/]>\\|$\\|\\_s\\=>\\)",
|
||||
(char_u *)"",
|
||||
(char_u *)"</[^>]*>", BACKWARD, (char_u *)"", 0,
|
||||
(char_u *)"</[^>]*>", BACKWARD, NULL, 0,
|
||||
NULL, (linenr_T)0, 0L) <= 0) {
|
||||
curwin->w_cursor = old_pos;
|
||||
goto theend;
|
||||
@@ -3459,7 +3459,7 @@ again:
|
||||
sprintf((char *)spat, "<%.*s\\>\\%%(\\s\\_[^>]\\{-}[^/]>\\|>\\)\\c", len, p);
|
||||
sprintf((char *)epat, "</%.*s>\\c", len, p);
|
||||
|
||||
r = do_searchpair(spat, (char_u *)"", epat, FORWARD, (char_u *)"",
|
||||
r = do_searchpair(spat, (char_u *)"", epat, FORWARD, NULL,
|
||||
0, NULL, (linenr_T)0, 0L);
|
||||
|
||||
xfree(spat);
|
||||
|
Reference in New Issue
Block a user