]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
runtime(vim): Update base-syntax and generator, generate command modifiers
authorDoug Kearns <dougkearns@gmail.com>
Thu, 3 Jul 2025 18:47:50 +0000 (20:47 +0200)
committerChristian Brabandt <cb@256bit.org>
Thu, 3 Jul 2025 18:47:50 +0000 (20:47 +0200)
Generate Ex command modifiers from the modifier table in src/ex_docmd.c

closes: #17564

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
14 files changed:
runtime/syntax/generator/gen_syntax_vim.vim
runtime/syntax/generator/vim.vim.base
runtime/syntax/testdir/dumps/vim_ex_command_modifiers_00.dump [new file with mode: 0644]
runtime/syntax/testdir/dumps/vim_ex_command_modifiers_01.dump [new file with mode: 0644]
runtime/syntax/testdir/dumps/vim_ex_command_modifiers_02.dump [new file with mode: 0644]
runtime/syntax/testdir/dumps/vim_ex_command_modifiers_03.dump [new file with mode: 0644]
runtime/syntax/testdir/dumps/vim_ex_command_modifiers_04.dump [new file with mode: 0644]
runtime/syntax/testdir/dumps/vim_ex_command_modifiers_05.dump [new file with mode: 0644]
runtime/syntax/testdir/dumps/vim_ex_command_modifiers_06.dump [new file with mode: 0644]
runtime/syntax/testdir/dumps/vim_ex_command_modifiers_07.dump [new file with mode: 0644]
runtime/syntax/testdir/dumps/vim_ex_filter_00.dump
runtime/syntax/testdir/input/vim_ex_command_modifiers.vim [new file with mode: 0644]
runtime/syntax/testdir/input/vim_ex_filter.vim
runtime/syntax/vim.vim

index f7a1cc5fed0bc749dd90109c49d88c74801de950..af1b9b492c6849bc2c4abb193ef69229a5a63f58 100644 (file)
@@ -234,16 +234,51 @@ function s:parse_vim_command(cmd)
        endtry
 endfunc
 
+function s:get_cmd_modifiers()
+       try
+               let file_name = $VIM_SRCDIR .. '/ex_docmd.c'
+
+               new
+               exec 'read ' .. file_name
+               norm! gg
+               exec ':/^static cmdmod_info_T cmdmod_info_tab\[] = {/+1;/^};/-1yank'
+               %delete _
+
+               put
+               1delete _
+
+               let modifiers = []
+               let list = []
+               for line in getline(1, line('$'))
+                       let list = matchlist(line, '^\s*{"\(\w\+\)".*')
+                       call add(modifiers, copy(list[1]))
+               endfor
+
+               quit!
+
+               if empty(modifiers)
+                       throw 'cmd modifiers list is empty'
+               endif
+
+               return modifiers
+
+       catch /.*/
+               call s:err_gen('')
+               throw 'exit'
+       endtry
+endfunction
+
 function s:get_vim_command_type(cmd_name)
        " Return value:
        "   0: normal
        "   1: (Reserved)
-       "   2: abbrev (without un)
+       "   2: abbrev
        "   3: menu
        "   4: map
        "   5: mapclear
        "   6: unmap
        "   7: abclear
+       "   8: modifiers
        "   99: (Exclude registration of "syn keyword")
        let ab_prefix   = '^[ci]\?'
        let menu_prefix = '^\%([acinostvx]\?\|tl\)'
@@ -362,7 +397,6 @@ function s:get_vim_command_type(cmd_name)
        EOL
        " Required for original behavior
        " \     'global', 'vglobal'
-
        if index(exclude_list, a:cmd_name) != -1
                let ret = 99
        elseif a:cmd_name =~# '^\%(\%(un\)\?abbreviate\|noreabbrev\|\l\%(nore\|un\)\?abbrev\)$'
@@ -377,6 +411,8 @@ function s:get_vim_command_type(cmd_name)
                let ret = 5
        elseif a:cmd_name =~# map_prefix . 'unmap$'
                let ret = 6
+       elseif index(s:get_cmd_modifiers(), a:cmd_name) != -1
+               let ret = 8
        else
                let ret = 0
        endif
@@ -805,6 +841,9 @@ function s:update_syntax_vim_file(vim_info)
                " vimCommand - menu
                let lnum = s:search_and_check(kword . ' menu', base_fname, str_info)
                let lnum = s:append_syn_vimcmd(lnum, str_info, li, 3)
+               " vimCommand - modifier
+               let lnum = s:search_and_check(kword . ' modifier', base_fname, str_info)
+               let lnum = s:append_syn_vimcmd(lnum, str_info, li, 8)
 
                update
                quit!
index c49486e482e4d8944816d4906c22c33b429b4814..e01e5f9d0f96f3c31088520d96e1fd0fc0214176 100644 (file)
@@ -2,7 +2,7 @@
 " Language:       Vim script
 " Maintainer:     Hirohito Higashi <h.east.727 ATMARK gmail.com>
 "         Doug Kearns <dougkearns@gmail.com>
-" Last Change:    2025 Jun 30
+" Last Change:    2025 Jul 03
 " Former Maintainer: Charles E. Campbell
 
 " DO NOT CHANGE DIRECTLY.
@@ -34,6 +34,10 @@ syn cluster vimCommentGroup  contains=vimTodo,@Spell
 " regular vim commands {{{2
 " GEN_SYN_VIM: vimCommand normal, START_STR='syn keyword vimCommand contained', END_STR='nextgroup=vimBang'
 
+" GEN_SYN_VIM: vimCommand modifier, START_STR='syn keyword vimCommandModifier', END_STR='skipwhite nextgroup=vimCommandModifierBang,@vimCmdList'
+" :filter is handled specially elsewhere
+syn match      vimCommandModifierBang  contained       "\a\@1<=!"      skipwhite nextgroup=@vimCmdList
+
 " Lower priority for _new_ to distinguish constructors from the command.
 syn match   vimCommand contained       "\<new\>(\@!"
 syn match   vimCommand contained       "\<z[-+^.=]\=\>"
@@ -226,7 +230,7 @@ syn match   vimNumber       '\<0z\%(\x\x\)\+\%(\.\%(\x\x\)\+\)*'    skipwhite nextgroup=@vi
 syn case match
 
 " All vimCommands are contained by vimIsCommand. {{{2
-syn cluster vimCmdList contains=vimAbb,vimAddress,vimAutocmd,vimAugroup,vimBehave,vimCall,vimCatch,vimConst,vimDoautocmd,vimDebuggreedy,vimDef,vimDefFold,vimDelcommand,vimDelFunction,@vimEcho,vimElse,vimEnddef,vimEndfunction,vimEndif,vimExecute,vimIsCommand,vimExtCmd,vimExFilter,vimExMark,vimFor,vimFunction,vimFunctionFold,vimGrep,vimGrepAdd,vimGlobal,vimHelpgrep,vimHighlight,vimImport,vimLet,vimLoadkeymap,vimLockvar,vimMake,vimMap,vimMark,vimMatch,vimNotFunc,vimNormal,vimProfdel,vimProfile,vimRedir,vimSet,vimSleep,vimSort,vimSyntax,vimThrow,vimUniq,vimUnlet,vimUnlockvar,vimUnmap,vimUserCmd,vimVimgrep,vimVimgrepadd,vimMenu,vimMenutranslate,@vim9CmdList,@vimExUserCmdList,vimLua,vimMzScheme,vimPerl,vimPython,vimPython3,vimPythonX,vimRuby,vimTcl
+syn cluster vimCmdList contains=vimAbb,vimAddress,vimAutocmd,vimAugroup,vimBehave,vimCall,vimCatch,vimCommandModifier,vimConst,vimDoautocmd,vimDebuggreedy,vimDef,vimDefFold,vimDelcommand,vimDelFunction,@vimEcho,vimElse,vimEnddef,vimEndfunction,vimEndif,vimExecute,vimIsCommand,vimExtCmd,vimExFilter,vimExMark,vimFor,vimFunction,vimFunctionFold,vimGrep,vimGrepAdd,vimGlobal,vimHelpgrep,vimHighlight,vimImport,vimLet,vimLoadkeymap,vimLockvar,vimMake,vimMap,vimMark,vimMatch,vimNotFunc,vimNormal,vimProfdel,vimProfile,vimRedir,vimSet,vimSleep,vimSort,vimSyntax,vimThrow,vimUniq,vimUnlet,vimUnlockvar,vimUnmap,vimUserCmd,vimVimgrep,vimVimgrepadd,vimMenu,vimMenutranslate,@vim9CmdList,@vimExUserCmdList,vimLua,vimMzScheme,vimPerl,vimPython,vimPython3,vimPythonX,vimRuby,vimTcl
 syn cluster vim9CmdList        contains=vim9Abstract,vim9Class,vim9Const,vim9Enum,vim9Export,vim9Final,vim9For,vim9Interface,vim9Type,vim9Var
 syn match vimCmdSep    "\\\@1<!|"      skipwhite nextgroup=@vimCmdList,vimSubst1,vimFunc
 syn match vimCmdSep    ":\+"   skipwhite nextgroup=@vimCmdList,vimSubst1
@@ -1242,7 +1246,6 @@ syn region        vimExecute
 " Filter: {{{2
 " ======
 syn match      vimExFilter             "\<filt\%[er]\>"        skipwhite nextgroup=vimExFilterBang,vimExFilterPattern
-syn match      vimExFilterBang  contained      "\a\@1<=!"      skipwhite nextgroup=vimExFilterPattern
 syn region     vimExFilterPattern contained
       \ start="[[:ident:]]"
       \ end="\ze[[:space:]\n]"
@@ -1257,6 +1260,7 @@ syn region        vimExFilterPattern contained
       \ skipwhite nextgroup=@vimCmdList
       \ contains=@vimSubstList
       \ oneline
+syn match      vimExFilterBang  contained      "\a\@1<=!"      skipwhite nextgroup=vimExFilterPattern
 
 " Grep and Make: {{{2
 " =============
@@ -2163,6 +2167,8 @@ if !exists("skip_vim_syntax_inits")
  hi def link vimCatch  vimCommand
  hi def link vimCmplxRepeat    SpecialChar
  hi def link vimCommand        Statement
+ hi def link vimCommandModifier        vimCommand
+ hi def link vimCommandModifierBang    vimBang
  hi def link vimComment        Comment
  hi def link vimCommentError   vimError
  hi def link vimCommentString  vimString
@@ -2197,7 +2203,7 @@ if !exists("skip_vim_syntax_inits")
  hi def link vimError  Error
  hi def link vimEscape Special
  hi def link vimExFilter       vimCommand
- hi def link vimExFilterBang   vimCommand
+ hi def link vimExFilterBang   vimBang
  hi def link vimExMark vimCommand
  hi def link vimFBVar  vimVar
  hi def link vimFgBgAttrib     vimHiAttrib
diff --git a/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_00.dump b/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_00.dump
new file mode 100644 (file)
index 0000000..f61fadb
--- /dev/null
@@ -0,0 +1,20 @@
+>"+0#0000e05#ffffff0| |V|i|m| |e|x| |c|o|m@1|a|n|d| |m|o|d|i|f|i|e|r|s| +0#0000000&@48
+@75
+@75
+@1|a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+@75
+|a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|b+0#af5f00255&|e|l|o|w|r|i|g|h|t| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|b+0#af5f00255&|o|t|r|i|g|h|t| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|b+0#af5f00255&|r|o|w|s|e| +0#0000000&@11|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|c+0#af5f00255&|o|n|f|i|r|m| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|f+0#af5f00255&|i|l|t|e|r| +0#0000000&@1|/+0#e000e06&|p+0#0000000&|a|t@1|e|r|n|/+0#e000e06&| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|f+0#af5f00255&|i|l|t|e|r|!| +0#0000000&|/+0#e000e06&|p+0#0000000&|a|t@1|e|r|n|/+0#e000e06&| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|h+0#af5f00255&|i|d|e| +0#0000000&@13|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|h+0#af5f00255&|o|r|i|z|o|n|t|a|l| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|k+0#af5f00255&|e@1|p|a|l|t| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|k+0#af5f00255&|e@1|p|j|u|m|p|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|k+0#af5f00255&|e@1|p|m|a|r|k|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|k+0#af5f00255&|e@1|p@1|a|t@1|e|r|n|s| +0#0000000&@5|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|l+0#af5f00255&|e|f|t|a|b|o|v|e| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+@57|1|,|1| @10|T|o|p| 
diff --git a/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_01.dump b/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_01.dump
new file mode 100644 (file)
index 0000000..3c2fac5
--- /dev/null
@@ -0,0 +1,20 @@
+|h+0#af5f00255#ffffff0|o|r|i|z|o|n|t|a|l| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|k+0#af5f00255&|e@1|p|a|l|t| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|k+0#af5f00255&|e@1|p|j|u|m|p|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|k+0#af5f00255&|e@1|p|m|a|r|k|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|k+0#af5f00255&|e@1|p@1|a|t@1|e|r|n|s| +0#0000000&@5|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+>l+0#af5f00255&|e|f|t|a|b|o|v|e| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|l+0#af5f00255&|e|g|a|c|y| +0#0000000&@11|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|l+0#af5f00255&|o|c|k|m|a|r|k|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|n+0#af5f00255&|o|a|u|t|o|c|m|d| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|n+0#af5f00255&|o|s|w|a|p|f|i|l|e| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|r+0#af5f00255&|i|g|h|t|b|e|l|o|w| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|s+0#af5f00255&|a|n|d|b|o|x| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|s+0#af5f00255&|i|l|e|n|t| +0#0000000&@11|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|s+0#af5f00255&|i|l|e|n|t|!| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|t+0#af5f00255&|a|b| +0#0000000&@14|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|t+0#af5f00255&|o|p|l|e|f|t| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|u+0#af5f00255&|n|s|i|l|e|n|t| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|v+0#af5f00255&|e|r|b|o|s|e| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|v+0#af5f00255&|e|r|t|i|c|a|l| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+@57|1|9|,|1| @9|1@1|%| 
diff --git a/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_02.dump b/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_02.dump
new file mode 100644 (file)
index 0000000..05b0489
--- /dev/null
@@ -0,0 +1,20 @@
+|v+0#af5f00255#ffffff0|e|r|t|i|c|a|l| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+|v+0#af5f00255&|i|m|9|c|m|d| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@46
+@75
+@75
+|:| @1|a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@6|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+@1>"+0#0000e05&| +0#0000000&|F+0#0000001#ffff4012|I|X|M|E|:+0#e000e06#ffffff0| +0#0000e05&|n|o|t| |a| |t|e|r|n|a|r|y| |o|p|e|r|a|t|o|r| |'|:|'| +0#0000000&@38
+@1|:+0#af5f00255&| +0#0000000&|a|b|o|v|e|l|e|f|t| @6|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+@2|:|a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@6|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+@75
+|:|a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|b+0#af5f00255&|e|l|o|w|r|i|g|h|t| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|b+0#af5f00255&|o|t|r|i|g|h|t| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|b+0#af5f00255&|r|o|w|s|e| +0#0000000&@11|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|c+0#af5f00255&|o|n|f|i|r|m| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|f+0#af5f00255&|i|l|t|e|r| +0#0000000&@1|/+0#e000e06&|p+0#0000000&|a|t@1|e|r|n|/+0#e000e06&| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|f+0#af5f00255&|i|l|t|e|r|!| +0#0000000&|/+0#e000e06&|p+0#0000000&|a|t@1|e|r|n|/+0#e000e06&| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|h+0#af5f00255&|i|d|e| +0#0000000&@13|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|h+0#af5f00255&|o|r|i|z|o|n|t|a|l| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|k+0#af5f00255&|e@1|p|a|l|t| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+@57|3|7|,|2| @9|2|6|%| 
diff --git a/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_03.dump b/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_03.dump
new file mode 100644 (file)
index 0000000..6af289d
--- /dev/null
@@ -0,0 +1,20 @@
+|:+0&#ffffff0|k+0#af5f00255&|e@1|p|a|l|t| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|k+0#af5f00255&|e@1|p|j|u|m|p|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|k+0#af5f00255&|e@1|p|m|a|r|k|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|k+0#af5f00255&|e@1|p@1|a|t@1|e|r|n|s| +0#0000000&@5|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|l+0#af5f00255&|e|f|t|a|b|o|v|e| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+>:|l+0#af5f00255&|e|g|a|c|y| +0#0000000&@11|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|l+0#af5f00255&|o|c|k|m|a|r|k|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|n+0#af5f00255&|o|a|u|t|o|c|m|d| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|n+0#af5f00255&|o|s|w|a|p|f|i|l|e| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|r+0#af5f00255&|i|g|h|t|b|e|l|o|w| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|s+0#af5f00255&|a|n|d|b|o|x| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|s+0#af5f00255&|i|l|e|n|t| +0#0000000&@11|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|s+0#af5f00255&|i|l|e|n|t|!| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|t+0#af5f00255&|a|b| +0#0000000&@14|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|t+0#af5f00255&|o|p|l|e|f|t| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|u+0#af5f00255&|n|s|i|l|e|n|t| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|v+0#af5f00255&|e|r|b|o|s|e| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|v+0#af5f00255&|e|r|t|i|c|a|l| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+|:|v+0#af5f00255&|i|m|9|c|m|d| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+@57|5@1|,|1| @9|4|2|%| 
diff --git a/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_04.dump b/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_04.dump
new file mode 100644 (file)
index 0000000..53ac039
--- /dev/null
@@ -0,0 +1,20 @@
+|:+0&#ffffff0|v+0#af5f00255&|i|m|9|c|m|d| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@45
+@75
+@75
+|e+0#af5f00255&|c|h|o||+0#0000000&|a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o||+0#0000000&| |a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+>e+0#af5f00255&|c|h|o| +0#0000000&|||a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+@75
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |b+0#af5f00255&|e|l|o|w|r|i|g|h|t| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |b+0#af5f00255&|o|t|r|i|g|h|t| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |b+0#af5f00255&|r|o|w|s|e| +0#0000000&@11|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |c+0#af5f00255&|o|n|f|i|r|m| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |f+0#af5f00255&|i|l|t|e|r| +0#0000000&@1|/+0#e000e06&|p+0#0000000&|a|t@1|e|r|n|/+0#e000e06&| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |f+0#af5f00255&|i|l|t|e|r|!| +0#0000000&|/+0#e000e06&|p+0#0000000&|a|t@1|e|r|n|/+0#e000e06&| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |h+0#af5f00255&|i|d|e| +0#0000000&@13|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |h+0#af5f00255&|o|r|i|z|o|n|t|a|l| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |k+0#af5f00255&|e@1|p|a|l|t| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |k+0#af5f00255&|e@1|p|j|u|m|p|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |k+0#af5f00255&|e@1|p|m|a|r|k|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+@57|7|3|,|1| @9|5|7|%| 
diff --git a/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_05.dump b/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_05.dump
new file mode 100644 (file)
index 0000000..2f09531
--- /dev/null
@@ -0,0 +1,20 @@
+|e+0#af5f00255#ffffff0|c|h|o| +0#0000000&||| |k+0#af5f00255&|e@1|p|m|a|r|k|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |k+0#af5f00255&|e@1|p@1|a|t@1|e|r|n|s| +0#0000000&@5|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |l+0#af5f00255&|e|f|t|a|b|o|v|e| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |l+0#af5f00255&|e|g|a|c|y| +0#0000000&@11|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |l+0#af5f00255&|o|c|k|m|a|r|k|s| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+>e+0#af5f00255&|c|h|o| +0#0000000&||| |n+0#af5f00255&|o|a|u|t|o|c|m|d| +0#0000000&@8|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |n+0#af5f00255&|o|s|w|a|p|f|i|l|e| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |r+0#af5f00255&|i|g|h|t|b|e|l|o|w| +0#0000000&@7|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |s+0#af5f00255&|a|n|d|b|o|x| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |s+0#af5f00255&|i|l|e|n|t| +0#0000000&@11|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |s+0#af5f00255&|i|l|e|n|t|!| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |t+0#af5f00255&|a|b| +0#0000000&@14|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |t+0#af5f00255&|o|p|l|e|f|t| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |u+0#af5f00255&|n|s|i|l|e|n|t| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |v+0#af5f00255&|e|r|b|o|s|e| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |v+0#af5f00255&|e|r|t|i|c|a|l| +0#0000000&@9|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+|e+0#af5f00255&|c|h|o| +0#0000000&||| |v+0#af5f00255&|i|m|9|c|m|d| +0#0000000&@10|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@39
+@75
+@75
+@57|9|1|,|1| @9|7|3|%| 
diff --git a/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_06.dump b/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_06.dump
new file mode 100644 (file)
index 0000000..9b089ae
--- /dev/null
@@ -0,0 +1,20 @@
+| +0&#ffffff0@74
+|a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&|b+0#af5f00255&|e|l|o|w|r|i|g|h|t| +0#0000000&|b+0#af5f00255&|o|t|r|i|g|h|t| +0#0000000&|b+0#af5f00255&|r|o|w|s|e| +0#0000000&|c+0#af5f00255&|o|n|f|i|r|m| +0#0000000&|f+0#af5f00255&|i|l|t|e|r| +0#0000000&|/+0#e000e06&|p+0#0000000&|a|t@1|e|r|n|/+0#e000e06&| +0#0000000&|f+0#af5f00255&|i|l|t|e|r|!| +0#0000000&|/+0#e000e06&|p+0#0000000&|a|t@1
+|e|r|n|/+0#e000e06&| +0#0000000&|h+0#af5f00255&|i|d|e| +0#0000000&|h+0#af5f00255&|o|r|i|z|o|n|t|a|l| +0#0000000&|k+0#af5f00255&|e@1|p|a|l|t| +0#0000000&|k+0#af5f00255&|e@1|p|j|u|m|p|s| +0#0000000&|k+0#af5f00255&|e@1|p|m|a|r|k|s| +0#0000000&|k+0#af5f00255&|e@1|p@1|a|t@1|e|r|n|s| +0#0000000&|l+0#af5f00255&|e|f|t|a|b|o|v|e| +0#0000000&|l+0#af5f00255&|e|g
+|a|c|y| +0#0000000&|l+0#af5f00255&|o|c|k|m|a|r|k|s| +0#0000000&|n+0#af5f00255&|o|a|u|t|o|c|m|d| +0#0000000&|n+0#af5f00255&|o|s|w|a|p|f|i|l|e| +0#0000000&|r+0#af5f00255&|i|g|h|t|b|e|l|o|w| +0#0000000&|s+0#af5f00255&|a|n|d|b|o|x| +0#0000000&|s+0#af5f00255&|i|l|e|n|t| +0#0000000&|s+0#af5f00255&|i|l|e|n|t|!| +0#0000000&|t+0#af5f00255&|a|b| +0#0000000&|t+0#af5f00255&|o
+|p|l|e|f|t| +0#0000000&|u+0#af5f00255&|n|s|i|l|e|n|t| +0#0000000&|v+0#af5f00255&|e|r|b|o|s|e| +0#0000000&|v+0#af5f00255&|e|r|t|i|c|a|l| +0#0000000&|v+0#af5f00255&|i|m|9|c|m|d| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@24
+>a+0#af5f00255&|b|o|v|e|l|e|f|t| +0#0000000&@65
+@6|\+0#e000e06&| +0#0000000&|b+0#af5f00255&|e|l|o|w|r|i|g|h|t| +0#0000000&@56
+@6|\+0#e000e06&| +0#0000000&|b+0#af5f00255&|o|t|r|i|g|h|t| +0#0000000&@58
+@6|\+0#e000e06&| +0#0000000&|b+0#af5f00255&|r|o|w|s|e| +0#0000000&@60
+@6|\+0#e000e06&| +0#0000000&|c+0#af5f00255&|o|n|f|i|r|m| +0#0000000&@59
+@6|\+0#e000e06&| +0#0000000&|f+0#af5f00255&|i|l|t|e|r| +0#0000000&@1|/+0#e000e06&|p+0#0000000&|a|t@1|e|r|n|/+0#e000e06&| +0#0000000&@49
+@6|\+0#e000e06&| +0#0000000&|f+0#af5f00255&|i|l|t|e|r|!| +0#0000000&|/+0#e000e06&|p+0#0000000&|a|t@1|e|r|n|/+0#e000e06&| +0#0000000&@49
+@6|\+0#e000e06&| +0#0000000&|h+0#af5f00255&|i|d|e| +0#0000000&@62
+@6|\+0#e000e06&| +0#0000000&|h+0#af5f00255&|o|r|i|z|o|n|t|a|l| +0#0000000&@56
+@6|\+0#e000e06&| +0#0000000&|k+0#af5f00255&|e@1|p|a|l|t| +0#0000000&@59
+@6|\+0#e000e06&| +0#0000000&|k+0#af5f00255&|e@1|p|j|u|m|p|s| +0#0000000&@57
+@6|\+0#e000e06&| +0#0000000&|k+0#af5f00255&|e@1|p|m|a|r|k|s| +0#0000000&@57
+@6|\+0#e000e06&| +0#0000000&|k+0#af5f00255&|e@1|p@1|a|t@1|e|r|n|s| +0#0000000&@54
+@6|\+0#e000e06&| +0#0000000&|l+0#af5f00255&|e|f|t|a|b|o|v|e| +0#0000000&@57
+@57|1|0|6|,|1| @8|8|6|%| 
diff --git a/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_07.dump b/runtime/syntax/testdir/dumps/vim_ex_command_modifiers_07.dump
new file mode 100644 (file)
index 0000000..be01800
--- /dev/null
@@ -0,0 +1,20 @@
+| +0&#ffffff0@5|\+0#e000e06&| +0#0000000&|l+0#af5f00255&|e|f|t|a|b|o|v|e| +0#0000000&@57
+@6|\+0#e000e06&| +0#0000000&|l+0#af5f00255&|e|g|a|c|y| +0#0000000&@60
+@6|\+0#e000e06&| +0#0000000&|l+0#af5f00255&|o|c|k|m|a|r|k|s| +0#0000000&@57
+@6|\+0#e000e06&| +0#0000000&|n+0#af5f00255&|o|a|u|t|o|c|m|d| +0#0000000&@57
+@6|\+0#e000e06&| +0#0000000&|n+0#af5f00255&|o|s|w|a|p|f|i|l|e| +0#0000000&@56
+@6>\+0#e000e06&| +0#0000000&|r+0#af5f00255&|i|g|h|t|b|e|l|o|w| +0#0000000&@56
+@6|\+0#e000e06&| +0#0000000&|s+0#af5f00255&|a|n|d|b|o|x| +0#0000000&@59
+@6|\+0#e000e06&| +0#0000000&|s+0#af5f00255&|i|l|e|n|t| +0#0000000&@60
+@6|\+0#e000e06&| +0#0000000&|s+0#af5f00255&|i|l|e|n|t|!| +0#0000000&@59
+@6|\+0#e000e06&| +0#0000000&|t+0#af5f00255&|a|b| +0#0000000&@63
+@6|\+0#e000e06&| +0#0000000&|t+0#af5f00255&|o|p|l|e|f|t| +0#0000000&@59
+@6|\+0#e000e06&| +0#0000000&|u+0#af5f00255&|n|s|i|l|e|n|t| +0#0000000&@58
+@6|\+0#e000e06&| +0#0000000&|v+0#af5f00255&|e|r|b|o|s|e| +0#0000000&@59
+@6|\+0#e000e06&| +0#0000000&|v+0#af5f00255&|e|r|t|i|c|a|l| +0#0000000&@58
+@6|\+0#e000e06&| +0#0000000&|v+0#af5f00255&|i|m|9|c|m|d| +0#0000000&@59
+@6|\+0#e000e06&| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@56
+@75
+|~+0#4040ff13&| @73
+|~| @73
+| +0#0000000&@56|1|2|4|,|7| @8|B|o|t| 
index 46ad3e8e45542e14d4bf3ff65eb77c3d4012011f..345ef7adcd99ab79d8670da7cafd8611c9a626a5 100644 (file)
@@ -8,13 +8,13 @@
 |f+0#af5f00255&|i|l|t|e|r| +0#0000000&@1|/+0#e000e06&|p+0#0000000&|a|\+0#e000e06&|%|(|t+0#0000000&@1|\+0#e000e06&|)|e+0#0000000&|r|n|/+0#e000e06&| +0#0000000&|o+0#af5f00255&|l|d|f|i|l|e|s| +0#0000000&@43
 |f+0#af5f00255&|i|l|t|e|r|!| +0#0000000&|/+0#e000e06&|p+0#0000000&|a|\+0#e000e06&|%|(|t+0#0000000&@1|\+0#e000e06&|)|e+0#0000000&|r|n|/+0#e000e06&| +0#0000000&|o+0#af5f00255&|l|d|f|i|l|e|s| +0#0000000&@43
 @75
+|f+0#af5f00255&|i|l|t|e|r| +0#0000000&@1|!+0#e000e06&|p+0#0000000&|a|\+0#e000e06&|%|(|t+0#0000000&@1|\+0#e000e06&|)|e+0#0000000&|r|n|!+0#e000e06&| +0#0000000&|o+0#af5f00255&|l|d|f|i|l|e|s| +0#0000000&@43
+|f+0#af5f00255&|i|l|t|e|r|!| +0#0000000&|!+0#e000e06&|p+0#0000000&|a|\+0#e000e06&|%|(|t+0#0000000&@1|\+0#e000e06&|)|e+0#0000000&|r|n|!+0#e000e06&| +0#0000000&|o+0#af5f00255&|l|d|f|i|l|e|s| +0#0000000&@43
+@75
 |f+0#af5f00255&|i|l|t|e|r| +0#0000000&@1|/+0#e000e06&|p+0#0000000&|a|\+0#e000e06&|%|(|t+0#0000000&|||t|\+0#e000e06&|)|e+0#0000000&|r|n|/+0#e000e06&| +0#0000000&|o+0#af5f00255&|l|d|f|i|l|e|s| +0#0000000&||+0#af5f00255&| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@29
 |f+0#af5f00255&|i|l|t|e|r|!| +0#0000000&|/+0#e000e06&|p+0#0000000&|a|\+0#e000e06&|%|(|t+0#0000000&|||t|\+0#e000e06&|)|e+0#0000000&|r|n|/+0#e000e06&| +0#0000000&|o+0#af5f00255&|l|d|f|i|l|e|s| +0#0000000&||+0#af5f00255&| +0#0000000&|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@29
 @75
 |~+0#4040ff13&| @73
 |~| @73
 |~| @73
-|~| @73
-|~| @73
-|~| @73
 | +0#0000000&@56|1|,|1| @10|A|l@1| 
diff --git a/runtime/syntax/testdir/input/vim_ex_command_modifiers.vim b/runtime/syntax/testdir/input/vim_ex_command_modifiers.vim
new file mode 100644 (file)
index 0000000..22fafb0
--- /dev/null
@@ -0,0 +1,135 @@
+" Vim ex command modifiers
+
+
+ aboveleft        echo "Foo"
+
+aboveleft         echo "Foo"
+belowright        echo "Foo"
+botright          echo "Foo"
+browse            echo "Foo"
+confirm           echo "Foo"
+filter  /pattern/ echo "Foo"
+filter! /pattern/ echo "Foo"
+hide              echo "Foo"
+horizontal        echo "Foo"
+keepalt           echo "Foo"
+keepjumps         echo "Foo"
+keepmarks         echo "Foo"
+keeppatterns      echo "Foo"
+leftabove         echo "Foo"
+legacy            echo "Foo"
+lockmarks         echo "Foo"
+noautocmd         echo "Foo"
+noswapfile        echo "Foo"
+rightbelow        echo "Foo"
+sandbox           echo "Foo"
+silent            echo "Foo"
+silent!           echo "Foo"
+tab               echo "Foo"
+topleft           echo "Foo"
+unsilent          echo "Foo"
+verbose           echo "Foo"
+vertical          echo "Foo"
+vim9cmd           echo "Foo"
+
+
+:  aboveleft       echo "Foo"
+ " FIXME: not a ternary operator ':'
+ : aboveleft       echo "Foo"
+  :aboveleft       echo "Foo"
+
+:aboveleft         echo "Foo"
+:belowright        echo "Foo"
+:botright          echo "Foo"
+:browse            echo "Foo"
+:confirm           echo "Foo"
+:filter  /pattern/ echo "Foo"
+:filter! /pattern/ echo "Foo"
+:hide              echo "Foo"
+:horizontal        echo "Foo"
+:keepalt           echo "Foo"
+:keepjumps         echo "Foo"
+:keepmarks         echo "Foo"
+:keeppatterns      echo "Foo"
+:leftabove         echo "Foo"
+:legacy            echo "Foo"
+:lockmarks         echo "Foo"
+:noautocmd         echo "Foo"
+:noswapfile        echo "Foo"
+:rightbelow        echo "Foo"
+:sandbox           echo "Foo"
+:silent            echo "Foo"
+:silent!           echo "Foo"
+:tab               echo "Foo"
+:topleft           echo "Foo"
+:unsilent          echo "Foo"
+:verbose           echo "Foo"
+:vertical          echo "Foo"
+:vim9cmd           echo "Foo"
+
+
+echo|aboveleft           echo "Foo"
+echo| aboveleft          echo "Foo"
+echo |aboveleft          echo "Foo"
+
+echo | aboveleft         echo "Foo"
+echo | belowright        echo "Foo"
+echo | botright          echo "Foo"
+echo | browse            echo "Foo"
+echo | confirm           echo "Foo"
+echo | filter  /pattern/ echo "Foo"
+echo | filter! /pattern/ echo "Foo"
+echo | hide              echo "Foo"
+echo | horizontal        echo "Foo"
+echo | keepalt           echo "Foo"
+echo | keepjumps         echo "Foo"
+echo | keepmarks         echo "Foo"
+echo | keeppatterns      echo "Foo"
+echo | leftabove         echo "Foo"
+echo | legacy            echo "Foo"
+echo | lockmarks         echo "Foo"
+echo | noautocmd         echo "Foo"
+echo | noswapfile        echo "Foo"
+echo | rightbelow        echo "Foo"
+echo | sandbox           echo "Foo"
+echo | silent            echo "Foo"
+echo | silent!           echo "Foo"
+echo | tab               echo "Foo"
+echo | topleft           echo "Foo"
+echo | unsilent          echo "Foo"
+echo | verbose           echo "Foo"
+echo | vertical          echo "Foo"
+echo | vim9cmd           echo "Foo"
+
+
+aboveleft belowright botright browse confirm filter /pattern/ filter! /pattern/ hide horizontal keepalt keepjumps keepmarks keeppatterns leftabove legacy lockmarks noautocmd noswapfile rightbelow sandbox silent silent! tab topleft unsilent verbose vertical vim9cmd echo "Foo"
+aboveleft
+      \ belowright
+      \ botright
+      \ browse
+      \ confirm
+      \ filter  /pattern/
+      \ filter! /pattern/
+      \ hide
+      \ horizontal
+      \ keepalt
+      \ keepjumps
+      \ keepmarks
+      \ keeppatterns
+      \ leftabove
+      \ legacy
+      \ lockmarks
+      \ noautocmd
+      \ noswapfile
+      \ rightbelow
+      \ sandbox
+      \ silent
+      \ silent!
+      \ tab
+      \ topleft
+      \ unsilent
+      \ verbose
+      \ vertical
+      \ vim9cmd
+      \ echo "Foo"
+
index baf28a1ea65689ce49f1e70a683c7567eb2f2343..0c8947f1d79dc801acc43d23b4b38567e7cccbb8 100644 (file)
@@ -8,6 +8,9 @@ filter! pa\%(tt\)ern  oldfiles
 filter  /pa\%(tt\)ern/ oldfiles
 filter! /pa\%(tt\)ern/ oldfiles
 
+filter  !pa\%(tt\)ern! oldfiles
+filter! !pa\%(tt\)ern! oldfiles
+
 filter  /pa\%(t|t\)ern/ oldfiles | echo "Foo"
 filter! /pa\%(t|t\)ern/ oldfiles | echo "Foo"
 
index d2aa2b6c949db3be1e3a9b487ed68b044204bfb4..78cf018a5f2fad6a873db831cd78d6f6a61d2f52 100644 (file)
@@ -2,7 +2,7 @@
 " Language:       Vim script
 " Maintainer:     Hirohito Higashi <h.east.727 ATMARK gmail.com>
 "         Doug Kearns <dougkearns@gmail.com>
-" Last Change:    2025 Jun 30
+" Last Change:    2025 Jul 03
 " Former Maintainer: Charles E. Campbell
 
 " DO NOT CHANGE DIRECTLY.
@@ -33,12 +33,16 @@ syn cluster vimCommentGroup contains=vimTodo,@Spell
 
 " regular vim commands {{{2
 " GEN_SYN_VIM: vimCommand normal, START_STR='syn keyword vimCommand contained', END_STR='nextgroup=vimBang'
-syn keyword vimCommand contained abo[veleft] al[l] ar[gs] arga[dd] argd[elete] argdo argded[upe] arge[dit] argg[lobal] argl[ocal] argu[ment] as[cii] b[uffer] bN[ext] ba[ll] bad[d] balt bd[elete] bel[owright] bf[irst] bl[ast] bm[odified] bn[ext] bo[tright] bp[revious] br[ewind] brea[k] breaka[dd] breakd[el] breakl[ist] bro[wse] buffers bufd[o] bun[load] bw[ipeout] c[hange] cN[ext] cNf[ile] cabo[ve] cad[dbuffer] cadde[xpr] caddf[ile] caf[ter] cb[uffer] cbe[fore] cbel[ow] cbo[ttom] cc ccl[ose] cd cdo ce[nter] cex[pr] cf[ile] cfd[o] cfir[st] cg[etfile] cgetb[uffer] cgete[xpr] chd[ir] changes che[ckpath] checkt[ime] chi[story] cl[ist] clip[reset] cla[st] clo[se] cle[arjumps] cn[ext] cnew[er] cnf[ile] co[py] col[der] colo[rscheme] com[mand] comc[lear] comp[iler] con[tinue] nextgroup=vimBang
-syn keyword vimCommand contained conf[irm] cons[t] cope[n] cp[revious] cpf[ile] cq[uit] cr[ewind] cs[cope] cst[ag] cw[indow] d[elete] delm[arks] deb[ug] defc[ompile] defe[r] di[splay] dif[fupdate] diffg[et] diffo[ff] diffp[atch] diffpu[t] diffs[plit] difft[his] dig[raphs] disa[ssemble] dj[ump] dli[st] dr[op] ds[earch] dsp[lit] e[dit] ea[rlier] em[enu] endfo[r] endt[ry] endw[hile] ene[w] ev[al] ex exi[t] exu[sage] f[ile] files filet[ype] fin[d] fina[lly] fini[sh] fir[st] fix[del] fo[ld] foldc[lose] foldd[oopen] folddoc[losed] foldo[pen] g[lobal] go[to] gu[i] gv[im] h[elp] helpc[lose] helpf[ind] helpt[ags] ha[rdcopy] hi[ghlight] hid[e] his[tory] hor[izontal] ij[ump] il[ist] int[ro] ip[ut] is[earch] isp[lit] j[oin] ju[mps] kee[pmarks] keepj[umps] keepp[atterns] keepa[lt] nextgroup=vimBang
-syn keyword vimCommand contained l[ist] lN[ext] lNf[ile] la[st] lab[ove] lan[guage] lad[dexpr] laddb[uffer] laddf[ile] laf[ter] lat[er] lb[uffer] lbe[fore] lbel[ow] lbo[ttom] lc[d] lch[dir] lcl[ose] lcs[cope] ld[o] le[ft] lefta[bove] lex[pr] leg[acy] lf[ile] lfd[o] lfir[st] lg[etfile] lgetb[uffer] lgete[xpr] lgr[ep] lgrepa[dd] lhi[story] ll lla[st] lli[st] lmak[e] lne[xt] lnew[er] lnf[ile] lo[adview] loc[kmarks] lockv[ar] lol[der] lop[en] lp[revious] lpf[ile] lr[ewind] lt[ag] lw[indow] ls m[ove] marks menut[ranslate] mes[sages] mk[exrc] mks[ession] mksp[ell] mkv[imrc] mkvie[w] mod[e] n[ext] nb[key] nbc[lose] nbs[tart] noa[utocmd] noh[lsearch] nos[wapfile] nu[mber] o[pen] ol[dfiles] on[ly] opt[ions] ow[nsyntax] p[rint] pa[ckadd] packl[oadall] pb[uffer] pc[lose] nextgroup=vimBang
-syn keyword vimCommand contained ped[it] po[p] pp[op] pre[serve] prev[ious] pro[mptfind] promptr[epl] ps[earch] pt[ag] ptN[ext] ptf[irst] ptj[ump] ptl[ast] ptn[ext] ptp[revious] ptr[ewind] pts[elect] pu[t] pw[d] q[uit] quita[ll] qa[ll] r[ead] rec[over] red[o] redr[aw] redraws[tatus] redrawt[abline] redrawtabp[anel] reg[isters] res[ize] ret[ab] rew[ind] ri[ght] rightb[elow] ru[ntime] rub[y] rubyd[o] rubyf[ile] rund[o] rv[iminfo] sN[ext] sa[rgument] sal[l] san[dbox] sav[eas] sb[uffer] sbN[ext] sba[ll] sbf[irst] sbl[ast] sbm[odified] sbn[ext] sbp[revious] sbr[ewind] scr[iptnames] scripte[ncoding] scriptv[ersion] scs[cope] setf[iletype] sf[ind] sfir[st] sh[ell] sim[alt] sig[n] sil[ent] sla[st] sn[ext] so[urce] sp[lit] spe[llgood] spelld[ump] spelli[nfo] spellr[epall] nextgroup=vimBang
-syn keyword vimCommand contained spellra[re] spellu[ndo] spellw[rong] spr[evious] sre[wind] st[op] sta[g] star[tinsert] startg[replace] startr[eplace] stopi[nsert] stj[ump] sts[elect] sun[hide] sus[pend] sv[iew] sw[apname] synti[me] sync[bind] smi[le] t tN[ext] ta[g] tags tab tabc[lose] tabd[o] tabe[dit] tabf[ind] tabfir[st] tabm[ove] tabl[ast] tabn[ext] tabnew tabo[nly] tabp[revious] tabN[ext] tabr[ewind] tabs tc[d] tch[dir] te[aroff] ter[minal] tf[irst] tj[ump] tl[ast] tn[ext] to[pleft] tp[revious] tr[ewind] try ts[elect] u[ndo] undoj[oin] undol[ist] unh[ide] unlo[ckvar] uns[ilent] up[date] v[global] ve[rsion] verb[ose] vert[ical] vi[sual] vie[w] vim9[cmd] viu[sage] vne[w] vs[plit] w[rite] wN[ext] wa[ll] wi[nsize] winc[md] wind[o] winp[os] wl[restore] wn[ext] nextgroup=vimBang
-syn keyword vimCommand contained wp[revious] wq wqa[ll] wu[ndo] wv[iminfo] x[it] xa[ll] xr[estore] y[ank] z dl dell delel deletl deletel dp dep delp delep deletp deletep a i nextgroup=vimBang
+syn keyword vimCommand contained al[l] ar[gs] arga[dd] argd[elete] argdo argded[upe] arge[dit] argg[lobal] argl[ocal] argu[ment] as[cii] b[uffer] bN[ext] ba[ll] bad[d] balt bd[elete] bf[irst] bl[ast] bm[odified] bn[ext] bp[revious] br[ewind] brea[k] breaka[dd] breakd[el] breakl[ist] buffers bufd[o] bun[load] bw[ipeout] c[hange] cN[ext] cNf[ile] cabo[ve] cad[dbuffer] cadde[xpr] caddf[ile] caf[ter] cb[uffer] cbe[fore] cbel[ow] cbo[ttom] cc ccl[ose] cd cdo ce[nter] cex[pr] cf[ile] cfd[o] cfir[st] cg[etfile] cgetb[uffer] cgete[xpr] chd[ir] changes che[ckpath] checkt[ime] chi[story] cl[ist] clip[reset] cla[st] clo[se] cle[arjumps] cn[ext] cnew[er] cnf[ile] co[py] col[der] colo[rscheme] com[mand] comc[lear] comp[iler] con[tinue] cons[t] cope[n] cp[revious] cpf[ile] nextgroup=vimBang
+syn keyword vimCommand contained cq[uit] cr[ewind] cs[cope] cst[ag] cw[indow] d[elete] delm[arks] deb[ug] defc[ompile] defe[r] di[splay] dif[fupdate] diffg[et] diffo[ff] diffp[atch] diffpu[t] diffs[plit] difft[his] dig[raphs] disa[ssemble] dj[ump] dli[st] dr[op] ds[earch] dsp[lit] e[dit] ea[rlier] em[enu] endfo[r] endt[ry] endw[hile] ene[w] ev[al] ex exi[t] exu[sage] f[ile] files filet[ype] fin[d] fina[lly] fini[sh] fir[st] fix[del] fo[ld] foldc[lose] foldd[oopen] folddoc[losed] foldo[pen] g[lobal] go[to] gu[i] gv[im] h[elp] helpc[lose] helpf[ind] helpt[ags] ha[rdcopy] hi[ghlight] his[tory] ij[ump] il[ist] int[ro] ip[ut] is[earch] isp[lit] j[oin] ju[mps] l[ist] lN[ext] lNf[ile] la[st] lab[ove] lan[guage] lad[dexpr] laddb[uffer] laddf[ile] laf[ter] lat[er] lb[uffer] nextgroup=vimBang
+syn keyword vimCommand contained lbe[fore] lbel[ow] lbo[ttom] lc[d] lch[dir] lcl[ose] lcs[cope] ld[o] le[ft] lex[pr] lf[ile] lfd[o] lfir[st] lg[etfile] lgetb[uffer] lgete[xpr] lgr[ep] lgrepa[dd] lhi[story] ll lla[st] lli[st] lmak[e] lne[xt] lnew[er] lnf[ile] lo[adview] lockv[ar] lol[der] lop[en] lp[revious] lpf[ile] lr[ewind] lt[ag] lw[indow] ls m[ove] marks menut[ranslate] mes[sages] mk[exrc] mks[ession] mksp[ell] mkv[imrc] mkvie[w] mod[e] n[ext] nb[key] nbc[lose] nbs[tart] noh[lsearch] nu[mber] o[pen] ol[dfiles] on[ly] opt[ions] ow[nsyntax] p[rint] pa[ckadd] packl[oadall] pb[uffer] pc[lose] ped[it] po[p] pp[op] pre[serve] prev[ious] pro[mptfind] promptr[epl] ps[earch] pt[ag] ptN[ext] ptf[irst] ptj[ump] ptl[ast] ptn[ext] ptp[revious] ptr[ewind] pts[elect] pu[t] nextgroup=vimBang
+syn keyword vimCommand contained pw[d] q[uit] quita[ll] qa[ll] r[ead] rec[over] red[o] redr[aw] redraws[tatus] redrawt[abline] redrawtabp[anel] reg[isters] res[ize] ret[ab] rew[ind] ri[ght] ru[ntime] rub[y] rubyd[o] rubyf[ile] rund[o] rv[iminfo] sN[ext] sa[rgument] sal[l] sav[eas] sb[uffer] sbN[ext] sba[ll] sbf[irst] sbl[ast] sbm[odified] sbn[ext] sbp[revious] sbr[ewind] scr[iptnames] scripte[ncoding] scriptv[ersion] scs[cope] setf[iletype] sf[ind] sfir[st] sh[ell] sim[alt] sig[n] sla[st] sn[ext] so[urce] sp[lit] spe[llgood] spelld[ump] spelli[nfo] spellr[epall] spellra[re] spellu[ndo] spellw[rong] spr[evious] sre[wind] st[op] sta[g] star[tinsert] startg[replace] startr[eplace] stopi[nsert] stj[ump] sts[elect] sun[hide] sus[pend] sv[iew] sw[apname] synti[me] sync[bind] nextgroup=vimBang
+syn keyword vimCommand contained smi[le] t tN[ext] ta[g] tags tabc[lose] tabd[o] tabe[dit] tabf[ind] tabfir[st] tabm[ove] tabl[ast] tabn[ext] tabnew tabo[nly] tabp[revious] tabN[ext] tabr[ewind] tabs tc[d] tch[dir] te[aroff] ter[minal] tf[irst] tj[ump] tl[ast] tn[ext] tp[revious] tr[ewind] try ts[elect] u[ndo] undoj[oin] undol[ist] unh[ide] unlo[ckvar] up[date] v[global] ve[rsion] vi[sual] vie[w] viu[sage] vne[w] vs[plit] w[rite] wN[ext] wa[ll] wi[nsize] winc[md] wind[o] winp[os] wl[restore] wn[ext] wp[revious] wq wqa[ll] wu[ndo] wv[iminfo] x[it] xa[ll] xr[estore] y[ank] z dl dell delel deletl deletel dp dep delp delep deletp deletep a i nextgroup=vimBang
+
+" GEN_SYN_VIM: vimCommand modifier, START_STR='syn keyword vimCommandModifier', END_STR='skipwhite nextgroup=vimCommandModifierBang,@vimCmdList'
+syn keyword vimCommandModifier abo[veleft] bel[owright] bo[tright] bro[wse] conf[irm] hid[e] hor[izontal] kee[pmarks] keepj[umps] keepp[atterns] keepa[lt] lefta[bove] leg[acy] loc[kmarks] noa[utocmd] nos[wapfile] rightb[elow] san[dbox] sil[ent] tab to[pleft] uns[ilent] verb[ose] vert[ical] vim9[cmd] skipwhite nextgroup=vimCommandModifierBang,@vimCmdList
+" :filter is handled specially elsewhere
+syn match      vimCommandModifierBang  contained       "\a\@1<=!"      skipwhite nextgroup=@vimCmdList
 
 " Lower priority for _new_ to distinguish constructors from the command.
 syn match   vimCommand contained       "\<new\>(\@!"
@@ -279,7 +283,7 @@ syn match   vimNumber       '\<0z\%(\x\x\)\+\%(\.\%(\x\x\)\+\)*'    skipwhite nextgroup=@vi
 syn case match
 
 " All vimCommands are contained by vimIsCommand. {{{2
-syn cluster vimCmdList contains=vimAbb,vimAddress,vimAutocmd,vimAugroup,vimBehave,vimCall,vimCatch,vimConst,vimDoautocmd,vimDebuggreedy,vimDef,vimDefFold,vimDelcommand,vimDelFunction,@vimEcho,vimElse,vimEnddef,vimEndfunction,vimEndif,vimExecute,vimIsCommand,vimExtCmd,vimExFilter,vimExMark,vimFor,vimFunction,vimFunctionFold,vimGrep,vimGrepAdd,vimGlobal,vimHelpgrep,vimHighlight,vimImport,vimLet,vimLoadkeymap,vimLockvar,vimMake,vimMap,vimMark,vimMatch,vimNotFunc,vimNormal,vimProfdel,vimProfile,vimRedir,vimSet,vimSleep,vimSort,vimSyntax,vimThrow,vimUniq,vimUnlet,vimUnlockvar,vimUnmap,vimUserCmd,vimVimgrep,vimVimgrepadd,vimMenu,vimMenutranslate,@vim9CmdList,@vimExUserCmdList,vimLua,vimMzScheme,vimPerl,vimPython,vimPython3,vimPythonX,vimRuby,vimTcl
+syn cluster vimCmdList contains=vimAbb,vimAddress,vimAutocmd,vimAugroup,vimBehave,vimCall,vimCatch,vimCommandModifier,vimConst,vimDoautocmd,vimDebuggreedy,vimDef,vimDefFold,vimDelcommand,vimDelFunction,@vimEcho,vimElse,vimEnddef,vimEndfunction,vimEndif,vimExecute,vimIsCommand,vimExtCmd,vimExFilter,vimExMark,vimFor,vimFunction,vimFunctionFold,vimGrep,vimGrepAdd,vimGlobal,vimHelpgrep,vimHighlight,vimImport,vimLet,vimLoadkeymap,vimLockvar,vimMake,vimMap,vimMark,vimMatch,vimNotFunc,vimNormal,vimProfdel,vimProfile,vimRedir,vimSet,vimSleep,vimSort,vimSyntax,vimThrow,vimUniq,vimUnlet,vimUnlockvar,vimUnmap,vimUserCmd,vimVimgrep,vimVimgrepadd,vimMenu,vimMenutranslate,@vim9CmdList,@vimExUserCmdList,vimLua,vimMzScheme,vimPerl,vimPython,vimPython3,vimPythonX,vimRuby,vimTcl
 syn cluster vim9CmdList        contains=vim9Abstract,vim9Class,vim9Const,vim9Enum,vim9Export,vim9Final,vim9For,vim9Interface,vim9Type,vim9Var
 syn match vimCmdSep    "\\\@1<!|"      skipwhite nextgroup=@vimCmdList,vimSubst1,vimFunc
 syn match vimCmdSep    ":\+"   skipwhite nextgroup=@vimCmdList,vimSubst1
@@ -1299,7 +1303,6 @@ syn region        vimExecute
 " Filter: {{{2
 " ======
 syn match      vimExFilter             "\<filt\%[er]\>"        skipwhite nextgroup=vimExFilterBang,vimExFilterPattern
-syn match      vimExFilterBang  contained      "\a\@1<=!"      skipwhite nextgroup=vimExFilterPattern
 syn region     vimExFilterPattern contained
       \ start="[[:ident:]]"
       \ end="\ze[[:space:]\n]"
@@ -1314,6 +1317,7 @@ syn region        vimExFilterPattern contained
       \ skipwhite nextgroup=@vimCmdList
       \ contains=@vimSubstList
       \ oneline
+syn match      vimExFilterBang  contained      "\a\@1<=!"      skipwhite nextgroup=vimExFilterPattern
 
 " Grep and Make: {{{2
 " =============
@@ -2224,6 +2228,8 @@ if !exists("skip_vim_syntax_inits")
  hi def link vimCatch  vimCommand
  hi def link vimCmplxRepeat    SpecialChar
  hi def link vimCommand        Statement
+ hi def link vimCommandModifier        vimCommand
+ hi def link vimCommandModifierBang    vimBang
  hi def link vimComment        Comment
  hi def link vimCommentError   vimError
  hi def link vimCommentString  vimString
@@ -2258,7 +2264,7 @@ if !exists("skip_vim_syntax_inits")
  hi def link vimError  Error
  hi def link vimEscape Special
  hi def link vimExFilter       vimCommand
- hi def link vimExFilterBang   vimCommand
+ hi def link vimExFilterBang   vimBang
  hi def link vimExMark vimCommand
  hi def link vimFBVar  vimVar
  hi def link vimFgBgAttrib     vimHiAttrib