Hi Bram,

2018-8-14(Tue) 23:53:06 UTC+9 h_east:
> Hi
> 
> 2018-8-14(Tue) 1:40:24 UTC+9 markonm:
> [...]
> 
> > :smagic and :snomagic would also be useful.
> 
> I am working in progress.
> It is done by adding a test 👍
> 
> Please wait a few hours.

Patch attached.
Please check it.

PS
Sorry, Screen dump test has not been added.

--
Best regards,
Hirohito Higashi (h_east)

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.
diff --git a/src/ex_getln.c b/src/ex_getln.c
index 8765ac5b2..061991ba7 100644
--- a/src/ex_getln.c
+++ b/src/ex_getln.c
@@ -298,6 +298,13 @@ do_incsearch_highlighting(int firstc, incsearch_state_T *is_state,
 			    || STRNCMP(cmd, "global", p - cmd) == 0
 			    || STRNCMP(cmd, "vglobal", p - cmd) == 0))
 		{
+		    // Check "global!/".
+		    if (STRNCMP(cmd, "global", p - cmd) == 0 && *p == '!')
+		    {
+			p++;
+			if (*skipwhite(p) == NUL)
+			    return FALSE;
+		    }
 		    p = skipwhite(p);
 		    delim = *p++;
 		    end = skip_regexp(p, delim, p_magic, NULL);
diff --git a/src/testdir/test_search.vim b/src/testdir/test_search.vim
index 05046b3c0..8d4b7cc60 100644
--- a/src/testdir/test_search.vim
+++ b/src/testdir/test_search.vim
@@ -399,6 +399,14 @@ func Test_search_cmdline3g()
   undo
   call feedkeys(":global/the\<c-l>/d\<cr>", 'tx')
   call assert_equal('  3 the theother', getline(2))
+  undo
+  call feedkeys(":g!/the\<c-l>/d\<cr>", 'tx')
+  call assert_equal(1, line('$'))
+  call assert_equal('  2 the~e', getline(1))
+  undo
+  call feedkeys(":global!/the\<c-l>/d\<cr>", 'tx')
+  call assert_equal(1, line('$'))
+  call assert_equal('  2 the~e', getline(1))
 
   call Incsearch_cleanup()
 endfunc

Raspunde prin e-mail lui