mirror of
https://github.com/vim/vim
synced 2025-07-15 16:51:57 +00:00
runtime(vim): Update base-syntax, match OR operator in :echo and :execute
Don't match the OR operator in expressions as a trailing bar. closes: #17533 Signed-off-by: Doug Kearns <dougkearns@gmail.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
committed by
Christian Brabandt
parent
74f0a77bb9
commit
a931371694
@ -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 20
|
||||
" Last Change: 2025 Jun 23
|
||||
" Former Maintainer: Charles E. Campbell
|
||||
|
||||
" DO NOT CHANGE DIRECTLY.
|
||||
@ -1223,8 +1223,12 @@ syn region vimEcho
|
||||
\ start="\<echoc\%[onsole]\>"
|
||||
\ start="\<echon\>"
|
||||
\ start="\<echow\%[indow]\>"
|
||||
\ skip=+\\|\|\n\s*\\\|\n\s*"\\ +
|
||||
\ matchgroup=vimCmdSep end="|" excludenl end="$" contains=@vimContinue,@vimExprList transparent
|
||||
\ skip=+\\|\|||\|\n\s*\%(\\\|["#]\\ \)+
|
||||
\ end="\ze|"
|
||||
\ excludenl end="$"
|
||||
\ nextgroup=vimCmdSep
|
||||
\ contains=@vimContinue,@vimExprList
|
||||
\ transparent
|
||||
|
||||
syn match vimEchohl "\<echohl\=\>" skipwhite nextgroup=vimGroup,vimHLGroup,vimEchohlNone
|
||||
syn case ignore
|
||||
@ -1233,7 +1237,15 @@ syn case match
|
||||
|
||||
syn cluster vimEcho contains=vimEcho,vimEchohl
|
||||
|
||||
syn region vimExecute matchgroup=vimCommand start="\<exe\%[cute]\>" skip=+\\|\|\n\s*\\\|\n\s*"\\ + matchgroup=vimCmdSep end="|" excludenl end="$" contains=@vimContinue,@vimExprList transparent
|
||||
syn region vimExecute
|
||||
\ matchgroup=vimCommand
|
||||
\ start="\<exe\%[cute]\>"
|
||||
\ skip=+\\|\|||\|\n\s*\%(\\\|["#]\\ \)+
|
||||
\ end="\ze|"
|
||||
\ excludenl end="$"
|
||||
\ nextgroup=vimCmdSep
|
||||
\ contains=@vimContinue,@vimExprList
|
||||
\ transparent
|
||||
|
||||
" Filter: {{{2
|
||||
" ======
|
||||
|
@ -1,5 +1,6 @@
|
||||
>"+0#0000e05#ffffff0| |V|i|m| |:|e|c|h|o| |c|o|m@1|a|n|d|s| +0#0000000&@54
|
||||
@75
|
||||
@75
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&@7|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&|4+0#e000002&|2| +0#0000000&@48
|
||||
|e+0#af5f00255&|c|h|o|n| +0#0000000&@6|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&|4+0#e000002&|2| +0#0000000&@48
|
||||
|e+0#af5f00255&|c|h|o|m|s|g| +0#0000000&@4|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&|4+0#e000002&|2| +0#0000000&@48
|
||||
@ -7,14 +8,13 @@
|
||||
|e+0#af5f00255&|c|h|o|e|r@1| +0#0000000&@4|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&|4+0#e000002&|2| +0#0000000&@48
|
||||
|e+0#af5f00255&|c|h|o|c|o|n|s|o|l|e| +0#0000000&|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&|4+0#e000002&|2| +0#0000000&@48
|
||||
@75
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|f|o|l@1|o|w|i|n|g| |c|o|m@1|a|n|d| |i|s| |:|||"| +0#0000000&||| ||| @40
|
||||
@75
|
||||
|e+0#af5f00255&|c|h|o|h|l| +0#0000000&|W+0#00e0003&|a|r|n|i|n|g|M|s|g| +0#0000000&||| |e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|D|o|n|'|t| |p|a|n|i|c|!|"| +0#0000000&||| |e+0#af5f00255&|c|h|o|h|l| +0#0000000&|N+0#00e0003&|o|n|e| +0#0000000&@21
|
||||
|"+0#0000e05&| |t|r|a|i|l|i|n|g| |b|a|r| |v|s| |O|R| |o|p|e|r|a|t|o|r| +0#0000000&@45
|
||||
@75
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&@58
|
||||
@5|"+0#0000e05&|\| |c|o|m@1|e|n|t| +0#0000000&@59
|
||||
@6|\+0#e000e06&| +0#0000000&|4+0#e000002&|2| +0#0000000&@64
|
||||
|"+0#0000e05&| |O|R| |o|p|e|r|a|t|o|r| +0#0000000&@61
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&||+0#af5f00255&@1| +0#0000000&|b+0#00e0e07&|a|r| +0#0000000&@59
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&||+0#af5f00255&@1| +0#0000000&@63
|
||||
@6|\+0#e000e06&| +0#0000000&|b+0#00e0e07&|a|r| +0#0000000&@63
|
||||
@75
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&@70
|
||||
@6|\+0#e000e06&| +0#0000000&|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&@55
|
||||
|"+0#0000e05&| |f|o|l@1|o|w|i|n|g| |c|o|m@1|a|n|d| |i|s| |:||| +0#0000000&@49
|
||||
@57|1|,|1| @10|T|o|p|
|
||||
|
@ -1,20 +1,20 @@
|
||||
|e+0#af5f00255#ffffff0|c|h|o| +0#0000000&|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&@58
|
||||
|"+0#0000e05#ffffff0| |O|R| |o|p|e|r|a|t|o|r| +0#0000000&@61
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&||+0#af5f00255&@1| +0#0000000&|b+0#00e0e07&|a|r| +0#0000000&@59
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&||+0#af5f00255&@1| +0#0000000&@63
|
||||
@6|\+0#e000e06&| +0#0000000&|b+0#00e0e07&|a|r| +0#0000000&@63
|
||||
@75
|
||||
>"+0#0000e05&| |f|o|l@1|o|w|i|n|g| |c|o|m@1|a|n|d| |i|s| |:||| +0#0000000&@49
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&||| ||| @60
|
||||
@75
|
||||
|"+0#0000e05&| |i|n|v|a|l|i|d| |e|x|p|r|e|s@1|i|o|n| +0#0000000&@54
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&||+0#af5f00255&@1| +0#0000000&@61
|
||||
@75
|
||||
|e+0#af5f00255&|c|h|o|h|l| +0#0000000&|W+0#00e0003&|a|r|n|i|n|g|M|s|g| +0#0000000&||| |e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|D|o|n|'|t| |p|a|n|i|c|!|"| +0#0000000&||| |e+0#af5f00255&|c|h|o|h|l| +0#0000000&|N+0#00e0003&|o|n|e| +0#0000000&@21
|
||||
@75
|
||||
@75
|
||||
|"+0#0000e05&| |l|i|n|e| |c|o|n|t|i|n|u|a|t|i|o|n|s| +0#0000000&@54
|
||||
@75
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&@58
|
||||
@5|"+0#0000e05&|\| |c|o|m@1|e|n|t| +0#0000000&@59
|
||||
@6|\+0#e000e06&| +0#0000000&|4+0#e000002&|2| +0#0000000&@64
|
||||
@75
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&@70
|
||||
@6>\+0#e000e06&| +0#0000000&|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&@55
|
||||
@5|"+0#0000e05&|\| |c|o|m@1|e|n|t| +0#0000000&@59
|
||||
@6|\+0#e000e06&| +0#0000000&|4+0#e000002&|2| +0#0000000&@64
|
||||
@75
|
||||
|"+0#0000e05&| |:|e|c|h|o| |w|i|t|h|o|u|t| |{|e|x|p|r|}| +0#0000000&@52
|
||||
|e+0#af5f00255&|c|h|o||+0#0000000&| |e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@58
|
||||
@75
|
||||
|"+0#0000e05&| |t|r|a|i|l|i|n|g| |c|o|m@1|e|n|t| |n|e@1|d|s| ||| +0#0000000&@48
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|f|o@1|"| +0#0000000&||| |"+0#0000e05&| |c|o|m@1|e|n|t| +0#0000000&@52
|
||||
@75
|
||||
@75
|
||||
|"+0#0000e05&| |I|s@1|u|e| |#|9@1|8|7| |(|p|a|r|e|n|t|h|e|s|i|s|e|d| |a|r|g|u|m|e|n|t| |-| |n|o|t| |a| |f|u|n|c|t|i|o|n| |c|a|l@1|)| +0#0000000&@14
|
||||
@75
|
||||
|l+0#af5f00255&|e|t| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&|=+0#af5f00255&| +0#0000000&|{+0#e000e06&|'+0#e000002&|e|n|d|'|:+0#0000000&| |1+0#e000002&|2|3|}+0#e000e06&| +0#0000000&@52
|
||||
@57|1|9|,|7| @9|6|8|%|
|
||||
@57|1|9|,|1| @9|3@1|%|
|
||||
|
@ -1,20 +1,20 @@
|
||||
|l+0#af5f00255#ffffff0|e|t| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&|=+0#af5f00255&| +0#0000000&|{+0#e000e06&|'+0#e000002&|e|n|d|'|:+0#0000000&| |1+0#e000002&|2|3|}+0#e000e06&| +0#0000000&@52
|
||||
| +0&#ffffff0@5|\+0#e000e06&| +0#0000000&|4+0#e000002&|2| +0#0000000&@64
|
||||
@75
|
||||
|i+0#af5f00255&|f| +0#0000000&|1+0#e000002&|2|3| +0#0000000&@68
|
||||
@8|e+0#af5f00255&|c|h|o| +0#0000000&|(+0#e000e06&|f+0#00e0e07&|o@1|.+0#af5f00255&|e+0#00e0e07&|n|d|)+0#e000e06&| +0#0000000&@52
|
||||
|e+0#af5f00255&|l|s|e| +0#0000000&@70
|
||||
@8>e+0#af5f00255&|c|h|o| +0#0000000&|'+0#e000002&|b|a|r|'| +0#0000000&@56
|
||||
|e+0#af5f00255&|n|d|i|f| +0#0000000&@69
|
||||
|~+0#4040ff13&| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
| +0#0000000&@56|3|7|,|2|-|9| @7|B|o|t|
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&@70
|
||||
@6|\+0#e000e06&| +0#0000000&|"+0#e000002&|A|n|s|w|e|r| |=| |"| +0#0000000&@55
|
||||
@5|"+0#0000e05&|\| |c|o|m@1|e|n|t| +0#0000000&@59
|
||||
@6>\+0#e000e06&| +0#0000000&|4+0#e000002&|2| +0#0000000&@64
|
||||
@75
|
||||
@75
|
||||
|"+0#0000e05&| |t|r|a|i|l|i|n|g| |b|a|r| |a|n|d| |c|o|m@1|e|n|t|s| +0#0000000&@47
|
||||
@75
|
||||
|"+0#0000e05&| |:|e|c|h|o| |w|i|t|h|o|u|t| |{|e|x|p|r|}| +0#0000000&@52
|
||||
|e+0#af5f00255&|c|h|o||+0#0000000&| |e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@58
|
||||
@75
|
||||
|"+0#0000e05&| |t|r|a|i|l|i|n|g| |c|o|m@1|e|n|t| |n|e@1|d|s| ||| +0#0000000&@48
|
||||
|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&||| |"+0#0000e05&| |c|o|m@1|e|n|t| +0#0000000&@52
|
||||
@75
|
||||
@75
|
||||
|"+0#0000e05&| |I|s@1|u|e| |#|9@1|8|7| |(|p|a|r|e|n|t|h|e|s|i|s|e|d| |a|r|g|u|m|e|n|t| |-| |n|o|t| |a| |f|u|n|c|t|i|o|n| |c|a|l@1|)| +0#0000000&@14
|
||||
@75
|
||||
@57|3|7|,|7| @9|7|9|%|
|
||||
|
20
runtime/syntax/testdir/dumps/vim_ex_echo_03.dump
Normal file
20
runtime/syntax/testdir/dumps/vim_ex_echo_03.dump
Normal file
@ -0,0 +1,20 @@
|
||||
| +0&#ffffff0@74
|
||||
|l+0#af5f00255&|e|t| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&|=+0#af5f00255&| +0#0000000&|{+0#e000e06&|'+0#e000002&|e|n|d|'|:+0#0000000&| |1+0#e000002&|2|3|}+0#e000e06&| +0#0000000&@52
|
||||
@75
|
||||
|i+0#af5f00255&|f| +0#0000000&|1+0#e000002&|2|3| +0#0000000&@68
|
||||
@8|e+0#af5f00255&|c|h|o| +0#0000000&|(+0#e000e06&|f+0#00e0e07&|o@1|.+0#af5f00255&|e+0#00e0e07&|n|d|)+0#e000e06&| +0#0000000&@52
|
||||
>e+0#af5f00255&|l|s|e| +0#0000000&@70
|
||||
@8|e+0#af5f00255&|c|h|o| +0#0000000&|'+0#e000002&|b|a|r|'| +0#0000000&@56
|
||||
|e+0#af5f00255&|n|d|i|f| +0#0000000&@69
|
||||
@75
|
||||
|~+0#4040ff13&| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
| +0#0000000&@56|5@1|,|1| @9|B|o|t|
|
@ -1,5 +1,6 @@
|
||||
>"+0#0000e05#ffffff0| |V|i|m| |:|e|x|e|c|u|t|e| |c|o|m@1|a|n|d| +0#0000000&@52
|
||||
@75
|
||||
@75
|
||||
|"+0#0000e05&| |:|h|e|l|p| |:|e|x|e|c|u|t|e| +0#0000000&@58
|
||||
@75
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|"+0#e000002&|b|u|f@1|e|r|"| +0#0000000&|n+0#00e0e07&|e|x|t|b|u|f| +0#0000000&@50
|
||||
@ -15,6 +16,5 @@
|
||||
|e+0#af5f00255&|n|d|i|f| +0#0000000&@69
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|'+0#e000002&|w|h|i|l|e| |i| |<| |5| ||| |e|c|h|o| |i| ||| |l|e|t| |i| |=| |i| |+| |1| ||| |e|n|d|w|h|i|l|e|'| +0#0000000&@17
|
||||
@75
|
||||
|"+0#0000e05&| |f|o|l@1|o|w|i|n|g| |c|o|m@1|a|n|d| |i|s| |:|||"| +0#0000000&@48
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|"+0#e000002&|c|a|l@1| |F|o@1|(|)|"| +0#0000000&||| ||| @50
|
||||
@75
|
||||
@57|1|,|1| @10|T|o|p|
|
||||
|
@ -1,20 +1,20 @@
|
||||
| +0&#ffffff0|e+0#af5f00255&|n|d|w|h|i|l|e| +0#0000000&@65
|
||||
| +0&#ffffff0@1|e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|t|e|s|t|"| +0#0000000&@61
|
||||
@1|e+0#af5f00255&|n|d|w|h|i|l|e| +0#0000000&@65
|
||||
|e+0#af5f00255&|n|d|i|f| +0#0000000&@69
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|'+0#e000002&|w|h|i|l|e| |i| |<| |5| ||| |e|c|h|o| |i| ||| |l|e|t| |i| |=| |i| |+| |1| ||| |e|n|d|w|h|i|l|e|'| +0#0000000&@17
|
||||
@75
|
||||
> @74
|
||||
|"+0#0000e05&| |t|r|a|i|l|i|n|g| |b|a|r| |v|s| |O|R| |o|p|e|r|a|t|o|r| +0#0000000&@45
|
||||
@75
|
||||
|"+0#0000e05&| |O|R| |o|p|e|r|a|t|o|r| +0#0000000&@61
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&||+0#af5f00255&@1| +0#0000000&|b+0#00e0e07&|a|r| +0#0000000&|?+0#af5f00255&| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&|:+0#af5f00255&| +0#0000000&|"+0#e000002&|N|o|t|F|o@1|"| +0#0000000&@37
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&||+0#af5f00255&@1| +0#0000000&@60
|
||||
@6|\+0#e000e06&| +0#0000000&|b+0#00e0e07&|a|r| +0#0000000&|?+0#af5f00255&| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&|:+0#af5f00255&| +0#0000000&|"+0#e000002&|N|o|t|F|o@1|"| +0#0000000&@44
|
||||
@75
|
||||
|"+0#0000e05&| |f|o|l@1|o|w|i|n|g| |c|o|m@1|a|n|d| |i|s| |:|||"| +0#0000000&@48
|
||||
>e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|"+0#e000002&|c|a|l@1| |F|o@1|(|)|"| +0#0000000&||| ||| @50
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&||| ||| @57
|
||||
@75
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|"+0#e000002&|c|a|l@1|"| +0#0000000&@60
|
||||
@6|"+0#0000e05&|\| |c|o|m@1|e|n|t| +0#0000000&@58
|
||||
@6|\+0#e000e06&| +0#0000000&|"+0#e000002&|F|o@1|(|)|"| +0#0000000&@59
|
||||
|"+0#0000e05&| |i|n|v|a|l|i|d| |e|x|p|r|e|s@1|i|o|n| +0#0000000&@54
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&||+0#af5f00255&@1| +0#0000000&@58
|
||||
@75
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&@67
|
||||
@6|\+0#e000e06&| +0#0000000&|"+0#e000002&|c|a|l@1|"| +0#0000000&@60
|
||||
@6|"+0#0000e05&|\| |c|o|m@1|e|n|t| +0#0000000&@58
|
||||
@6|\+0#e000e06&| +0#0000000&|"+0#e000002&|F|o@1|(|)|"| +0#0000000&@59
|
||||
@75
|
||||
|"+0#0000e05&| |:|e|x|e|c|u|t|e| |w|i|t|h|o|u|t| |{|e|x|p|r|}| +0#0000000&@49
|
||||
|e+0#af5f00255&|x|e|c|u|t|e||+0#0000000&| |e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@55
|
||||
@75
|
||||
@57|1|9|,|1| @9|5|9|%|
|
||||
@57|1|9|,|0|-|1| @7|3|1|%|
|
||||
|
@ -1,20 +1,20 @@
|
||||
| +0&#ffffff0@74
|
||||
|"+0#0000e05&| |t|r|a|i|l|i|n|g| |c|o|m@1|e|n|t| |n|e@1|d|s| ||| +0#0000000&@48
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|"+0#e000002&|f|o@1|"| +0#0000000&||| |"+0#0000e05&| |c|o|m@1|e|n|t| +0#0000000&@49
|
||||
@75
|
||||
|"+0#0000e05&| |l|i|n|e| |c|o|n|t|i|n|u|a|t|i|o|n|s| +0#0000000&@54
|
||||
@75
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|"+0#e000002&|c|a|l@1|"| +0#0000000&@60
|
||||
@6>"+0#0000e05&|\| |c|o|m@1|e|n|t| +0#0000000&@58
|
||||
@6|\+0#e000e06&| +0#0000000&|"+0#e000002&|F|o@1|(|)|"| +0#0000000&@59
|
||||
@75
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&@67
|
||||
@6|\+0#e000e06&| +0#0000000&|"+0#e000002&|c|a|l@1|"| +0#0000000&@60
|
||||
@6|"+0#0000e05&|\| |c|o|m@1|e|n|t| +0#0000000&@58
|
||||
@6|\+0#e000e06&| +0#0000000&|"+0#e000002&|F|o@1|(|)|"| +0#0000000&@59
|
||||
@75
|
||||
@75
|
||||
>"+0#0000e05&| |I|s@1|u|e| |#|9@1|8|7| |(|p|a|r|e|n|t|h|e|s|i|s|e|d| |a|r|g|u|m|e|n|t| |-| |n|o|t| |a| |f|u|n|c|t|i|o|n| |c|a|l@1|)| +0#0000000&@14
|
||||
|"+0#0000e05&| |t|r|a|i|l|i|n|g| |b|a|r| |a|n|d| |c|o|m@1|e|n|t|s| +0#0000000&@47
|
||||
@75
|
||||
|"+0#0000e05&| +0#0000000&|F+0#0000001#ffff4012|I|X|M|E|:+0#e000e06#ffffff0| +0#0000e05&|e|x|e|c|u|t|e| |i|s| |e|x| |c|o|m@1|a|n|d| |n|o|t| |b|u|i|l|t|i|n| |f|u|n|c|t|i|o|n| +0#0000000&@23
|
||||
|l+0#af5f00255&|e|t| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&|=+0#af5f00255&| +0#0000000&|{+0#e000e06&|'+0#e000002&|a|r|g|'|:+0#0000000&| |"+0#e000002&|c|a|l@1| |F|o@1|(|)|"|}+0#e000e06&| +0#0000000&@43
|
||||
|e+0#00e0e07&|x|e|c|u|t|e| +0#0000000&|(+0#e000e06&|f+0#00e0e07&|o@1|.+0#af5f00255&|a+0#00e0e07&|r|g|)+0#e000e06&| +0#0000000&@57
|
||||
|~+0#4040ff13&| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
| +0#0000000&@56|3|7|,|1| @9|B|o|t|
|
||||
|"+0#0000e05&| |:|e|x|e|c|u|t|e| |w|i|t|h|o|u|t| |{|e|x|p|r|}| +0#0000000&@49
|
||||
|e+0#af5f00255&|x|e|c|u|t|e||+0#0000000&| |e+0#af5f00255&|c|h|o| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&@55
|
||||
@75
|
||||
@57|3|7|,|7| @9|7|5|%|
|
||||
|
20
runtime/syntax/testdir/dumps/vim_ex_execute_03.dump
Normal file
20
runtime/syntax/testdir/dumps/vim_ex_execute_03.dump
Normal file
@ -0,0 +1,20 @@
|
||||
| +0&#ffffff0@74
|
||||
|"+0#0000e05&| |t|r|a|i|l|i|n|g| |c|o|m@1|e|n|t| |n|e@1|d|s| ||| +0#0000000&@48
|
||||
|e+0#af5f00255&|x|e|c|u|t|e| +0#0000000&|"+0#e000002&|F|o@1|"| +0#0000000&||| |"+0#0000e05&| |c|o|m@1|e|n|t| +0#0000000&@49
|
||||
@75
|
||||
@75
|
||||
>"+0#0000e05&| |I|s@1|u|e| |#|9@1|8|7| |(|p|a|r|e|n|t|h|e|s|i|s|e|d| |a|r|g|u|m|e|n|t| |-| |n|o|t| |a| |f|u|n|c|t|i|o|n| |c|a|l@1|)| +0#0000000&@14
|
||||
@75
|
||||
|"+0#0000e05&| +0#0000000&|F+0#0000001#ffff4012|I|X|M|E|:+0#e000e06#ffffff0| +0#0000e05&|e|x|e|c|u|t|e| |i|s| |e|x| |c|o|m@1|a|n|d| |n|o|t| |b|u|i|l|t|i|n| |f|u|n|c|t|i|o|n| +0#0000000&@23
|
||||
|l+0#af5f00255&|e|t| +0#0000000&|f+0#00e0e07&|o@1| +0#0000000&|=+0#af5f00255&| +0#0000000&|{+0#e000e06&|'+0#e000002&|a|r|g|'|:+0#0000000&| |"+0#e000002&|c|a|l@1| |F|o@1|(|)|"|}+0#e000e06&| +0#0000000&@43
|
||||
|e+0#00e0e07&|x|e|c|u|t|e| +0#0000000&|(+0#e000e06&|f+0#00e0e07&|o@1|.+0#af5f00255&|a+0#00e0e07&|r|g|)+0#e000e06&| +0#0000000&@57
|
||||
@75
|
||||
|~+0#4040ff13&| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
|~| @73
|
||||
| +0#0000000&@56|5@1|,|1| @9|B|o|t|
|
@ -1,5 +1,6 @@
|
||||
" Vim :echo commands
|
||||
|
||||
|
||||
echo "Answer = " 42
|
||||
echon "Answer = " 42
|
||||
echomsg "Answer = " 42
|
||||
@ -7,10 +8,25 @@ echowindow "Answer = " 42
|
||||
echoerr "Answer = " 42
|
||||
echoconsole "Answer = " 42
|
||||
|
||||
echo "following command is :|" | |
|
||||
|
||||
" trailing bar vs OR operator
|
||||
|
||||
" OR operator
|
||||
echo foo || bar
|
||||
echo foo ||
|
||||
\ bar
|
||||
|
||||
" following command is :|
|
||||
echo "Foo" | |
|
||||
|
||||
" invalid expression
|
||||
echo "Foo" ||
|
||||
|
||||
echohl WarningMsg | echo "Don't panic!" | echohl None
|
||||
|
||||
|
||||
" line continuations
|
||||
|
||||
echo "Answer = "
|
||||
"\ comment
|
||||
\ 42
|
||||
@ -20,11 +36,14 @@ echo
|
||||
"\ comment
|
||||
\ 42
|
||||
|
||||
|
||||
" trailing bar and comments
|
||||
|
||||
" :echo without {expr}
|
||||
echo| echo "Foo"
|
||||
|
||||
" trailing comment needs |
|
||||
echo "foo" | " comment
|
||||
echo "Foo" | " comment
|
||||
|
||||
|
||||
" Issue #9987 (parenthesised argument - not a function call)
|
||||
@ -36,3 +55,4 @@ if 123
|
||||
else
|
||||
echo 'bar'
|
||||
endif
|
||||
|
||||
|
@ -1,5 +1,6 @@
|
||||
" Vim :execute command
|
||||
|
||||
|
||||
" :help :execute
|
||||
|
||||
execute "buffer" nextbuf
|
||||
@ -15,8 +16,22 @@ if 0
|
||||
endif
|
||||
execute 'while i < 5 | echo i | let i = i + 1 | endwhile'
|
||||
|
||||
|
||||
" trailing bar vs OR operator
|
||||
|
||||
" OR operator
|
||||
execute foo || bar ? "Foo" : "NotFoo"
|
||||
execute foo ||
|
||||
\ bar ? "Foo" : "NotFoo"
|
||||
|
||||
" following command is :|"
|
||||
execute "call Foo()" | |
|
||||
execute "Foo" | |
|
||||
|
||||
" invalid expression
|
||||
execute "Foo" ||
|
||||
|
||||
|
||||
" line continuations
|
||||
|
||||
execute "call"
|
||||
"\ comment
|
||||
@ -27,11 +42,14 @@ execute
|
||||
"\ comment
|
||||
\ "Foo()"
|
||||
|
||||
|
||||
" trailing bar and comments
|
||||
|
||||
" :execute without {expr}
|
||||
execute| echo "Foo"
|
||||
|
||||
" trailing comment needs |
|
||||
execute "foo" | " comment
|
||||
execute "Foo" | " comment
|
||||
|
||||
|
||||
" Issue #9987 (parenthesised argument - not a function call)
|
||||
@ -39,3 +57,4 @@ execute "foo" | " comment
|
||||
" FIXME: execute is ex command not builtin function
|
||||
let foo = {'arg': "call Foo()"}
|
||||
execute (foo.arg)
|
||||
|
||||
|
@ -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 20
|
||||
" Last Change: 2025 Jun 23
|
||||
" Former Maintainer: Charles E. Campbell
|
||||
|
||||
" DO NOT CHANGE DIRECTLY.
|
||||
@ -1280,8 +1280,12 @@ syn region vimEcho
|
||||
\ start="\<echoc\%[onsole]\>"
|
||||
\ start="\<echon\>"
|
||||
\ start="\<echow\%[indow]\>"
|
||||
\ skip=+\\|\|\n\s*\\\|\n\s*"\\ +
|
||||
\ matchgroup=vimCmdSep end="|" excludenl end="$" contains=@vimContinue,@vimExprList transparent
|
||||
\ skip=+\\|\|||\|\n\s*\%(\\\|["#]\\ \)+
|
||||
\ end="\ze|"
|
||||
\ excludenl end="$"
|
||||
\ nextgroup=vimCmdSep
|
||||
\ contains=@vimContinue,@vimExprList
|
||||
\ transparent
|
||||
|
||||
syn match vimEchohl "\<echohl\=\>" skipwhite nextgroup=vimGroup,vimHLGroup,vimEchohlNone
|
||||
syn case ignore
|
||||
@ -1290,7 +1294,15 @@ syn case match
|
||||
|
||||
syn cluster vimEcho contains=vimEcho,vimEchohl
|
||||
|
||||
syn region vimExecute matchgroup=vimCommand start="\<exe\%[cute]\>" skip=+\\|\|\n\s*\\\|\n\s*"\\ + matchgroup=vimCmdSep end="|" excludenl end="$" contains=@vimContinue,@vimExprList transparent
|
||||
syn region vimExecute
|
||||
\ matchgroup=vimCommand
|
||||
\ start="\<exe\%[cute]\>"
|
||||
\ skip=+\\|\|||\|\n\s*\%(\\\|["#]\\ \)+
|
||||
\ end="\ze|"
|
||||
\ excludenl end="$"
|
||||
\ nextgroup=vimCmdSep
|
||||
\ contains=@vimContinue,@vimExprList
|
||||
\ transparent
|
||||
|
||||
" Filter: {{{2
|
||||
" ======
|
||||
|
Reference in New Issue
Block a user