aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2019-08-02 15:10:04 +0200
committerGitHub <noreply@github.com>2019-08-02 15:10:04 +0200
commit7cf0119c6857846fd1f254feb237f6137f140856 (patch)
tree1fb4d7c43a6cd86d7758bc0dc2d2aa23240b5947
parentb92a5bc3c4bdfddfc21638556ace6ef3fd90155c (diff)
parent532ee54a42a294073e8b441f3ce5a050d16963a2 (diff)
downloadrneovim-7cf0119c6857846fd1f254feb237f6137f140856.tar.gz
rneovim-7cf0119c6857846fd1f254feb237f6137f140856.tar.bz2
rneovim-7cf0119c6857846fd1f254feb237f6137f140856.zip
Merge #10666 from justinmk/vim-runtime
vim-patch: runtime updates
-rw-r--r--runtime/autoload/dist/ft.vim2
-rw-r--r--runtime/doc/autocmd.txt12
-rw-r--r--runtime/doc/change.txt2
-rw-r--r--runtime/doc/digraph.txt4
-rw-r--r--runtime/doc/eval.txt36
-rw-r--r--runtime/doc/filetype.txt9
-rw-r--r--runtime/doc/indent.txt5
-rw-r--r--runtime/doc/index.txt39
-rw-r--r--runtime/doc/message.txt6
-rw-r--r--runtime/doc/motion.txt4
-rw-r--r--runtime/doc/options.txt28
-rw-r--r--runtime/doc/pattern.txt4
-rw-r--r--runtime/doc/pi_netrw.txt6
-rw-r--r--runtime/doc/print.txt13
-rw-r--r--runtime/doc/russian.txt3
-rw-r--r--runtime/doc/spell.txt10
-rw-r--r--runtime/doc/tagsrch.txt6
-rw-r--r--runtime/doc/usr_05.txt2
-rw-r--r--runtime/doc/usr_41.txt1
-rw-r--r--runtime/doc/usr_45.txt6
-rw-r--r--runtime/doc/vi_diff.txt6
-rw-r--r--runtime/doc/visual.txt2
-rw-r--r--runtime/doc/windows.txt6
-rw-r--r--runtime/filetype.vim34
-rw-r--r--runtime/ftplugin/8th.vim25
-rw-r--r--runtime/ftplugin/cobol.vim5
-rw-r--r--runtime/ftplugin/dosbatch.vim3
-rw-r--r--runtime/ftplugin/make.vim6
-rw-r--r--runtime/ftplugin/nroff.vim11
-rw-r--r--runtime/ftplugin/ocaml.vim4
-rw-r--r--runtime/ftplugin/python.vim133
-rw-r--r--runtime/ftplugin/rst.vim2
-rw-r--r--runtime/ftplugin/sql.vim6
-rw-r--r--runtime/indent/awk.vim2
-rw-r--r--runtime/indent/cobol.vim11
-rw-r--r--runtime/indent/html.vim11
-rw-r--r--runtime/indent/mma.vim2
-rw-r--r--runtime/indent/python.vim104
-rw-r--r--runtime/indent/rmd.vim2
-rw-r--r--runtime/indent/sh.vim28
-rw-r--r--runtime/indent/testdir/html.ok6
-rw-r--r--runtime/indent/testdir/xml.ok4
-rw-r--r--runtime/indent/xml.vim63
-rw-r--r--runtime/syntax/8th.vim335
-rw-r--r--runtime/syntax/c.vim20
-rw-r--r--runtime/syntax/cobol.vim164
-rw-r--r--runtime/syntax/dcl.vim10
-rw-r--r--runtime/syntax/debchangelog.vim4
-rw-r--r--runtime/syntax/debsources.vim7
-rw-r--r--runtime/syntax/html.vim82
-rw-r--r--runtime/syntax/lisp.vim10
-rw-r--r--runtime/syntax/make.vim27
-rw-r--r--runtime/syntax/maple.vim10
-rw-r--r--runtime/syntax/rmd.vim10
-rw-r--r--runtime/syntax/sh.vim6
-rw-r--r--runtime/syntax/spec.vim6
-rw-r--r--runtime/syntax/template.vim15
-rw-r--r--runtime/syntax/tex.vim17
-rw-r--r--runtime/syntax/vim.vim2
-rw-r--r--runtime/syntax/yacc.vim17
60 files changed, 1075 insertions, 341 deletions
diff --git a/runtime/autoload/dist/ft.vim b/runtime/autoload/dist/ft.vim
index a97bad3b56..e85ffc763b 100644
--- a/runtime/autoload/dist/ft.vim
+++ b/runtime/autoload/dist/ft.vim
@@ -1,7 +1,7 @@
" Vim functions for file type detection
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
-" Last Change: 2019 Jan 18
+" Last Change: 2019 Mar 08
" These functions are moved here from runtime/filetype.vim to make startup
" faster.
diff --git a/runtime/doc/autocmd.txt b/runtime/doc/autocmd.txt
index 47afc4bd21..e37fe9e5ce 100644
--- a/runtime/doc/autocmd.txt
+++ b/runtime/doc/autocmd.txt
@@ -597,7 +597,7 @@ CompleteChanged *CompleteChanged*
recursively.
Sets these |v:event| keys:
- completed_item
+ completed_item See |complete-items|.
height nr of items visible
width screen cells
row top screen row
@@ -648,6 +648,7 @@ CursorMoved After the cursor was moved in Normal or Visual
Not triggered when there is typeahead or when
an operator is pending.
For an example see |match-parens|.
+ Note: Cannot be skipped with `:noautocmd`.
Careful: This is triggered very often, don't
do anything that the user does not expect or
that is slow.
@@ -1050,6 +1051,8 @@ TextChanged After a change was made to the text in the
was defined).
Not triggered when there is typeahead or when
an operator is pending.
+ Note: This can not be skipped with
+ `:noautocmd`.
Careful: This is triggered very often, don't
do anything that the user does not expect or
that is slow.
@@ -1474,8 +1477,8 @@ If you want the buffer to be unmodified after changing it, reset the
instead of ":q!".
*autocmd-nested* *E218*
-By default, autocommands do not nest. If you use ":e" or ":w" in an
-autocommand, Vim does not execute the BufRead and BufWrite autocommands for
+By default, autocommands do not nest. For example, if you use ":e" or ":w" in
+an autocommand, Vim does not execute the BufRead and BufWrite autocommands for
those commands. If you do want this, use the "++nested" flag for those
commands in which you want nesting. For example: >
:autocmd FileChangedShell *.c ++nested e!
@@ -1621,5 +1624,8 @@ following command. Example: >
This will write the file without triggering the autocommands defined by the
gzip plugin.
+Note that some autocommands are not triggered right away, but only later.
+This specifically applies to |CursorMoved| and |TextChanged|.
+
vim:tw=78:ts=8:noet:ft=help:norl:
diff --git a/runtime/doc/change.txt b/runtime/doc/change.txt
index ee70e95ab2..2259eddb6a 100644
--- a/runtime/doc/change.txt
+++ b/runtime/doc/change.txt
@@ -600,11 +600,11 @@ Directory for temporary files is created in the first suitable directory of:
For the {pattern} see |pattern|.
{string} can be a literal string, or something
special; see |sub-replace-special|.
- *E939*
When [range] and [count] are omitted, replace in the
current line only. When [count] is given, replace in
[count] lines, starting with the last line in [range].
When [range] is omitted start in the current line.
+ *E939*
[count] must be a positive number. Also see
|cmdline-ranges|.
diff --git a/runtime/doc/digraph.txt b/runtime/doc/digraph.txt
index 953a65f125..b106e625f2 100644
--- a/runtime/doc/digraph.txt
+++ b/runtime/doc/digraph.txt
@@ -50,6 +50,10 @@ conversion to be available, it might fail. For the NUL character you will see
"10". That's because NUL characters are internally represented with a NL
character. When you write the file it will become a NUL character.
+Example: >
+ digraph oe 339
+This defines the "oe" digraph for a character that is number 339 in Unicode.
+
==============================================================================
2. Using digraphs *digraphs-use*
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt
index 1a5268faf3..57ef380cc5 100644
--- a/runtime/doc/eval.txt
+++ b/runtime/doc/eval.txt
@@ -2245,6 +2245,7 @@ py3eval({expr}) any evaluate |python3| expression
pyxeval({expr}) any evaluate |python_x| expression
range({expr} [, {max} [, {stride}]])
List items from {expr} to {max}
+readdir({dir} [, {expr}]) List file names in {dir} selected by {expr}
readfile({fname} [, {binary} [, {max}]])
List get list of lines from file {fname}
reg_executing() Number get the executing register name
@@ -2576,9 +2577,9 @@ assert_false({actual} [, {msg}]) *assert_false()*
"Expected False but got {actual}" is produced.
assert_inrange({lower}, {upper}, {actual} [, {msg}]) *assert_inrange()*
- This asserts number values. When {actual} is lower than
- {lower} or higher than {upper} an error message is added to
- |v:errors|.
+ This asserts number and |Float| values. When {actual} is lower
+ than {lower} or higher than {upper} an error message is added
+ to |v:errors|. Also see |assert-return|.
When {msg} is omitted an error in the form
"Expected range {lower} - {upper}, but got {actual}" is
produced.
@@ -3009,7 +3010,7 @@ complete_info([{what}])
completion. See |ins-completion|.
The items are:
mode Current completion mode name string.
- See |completion_info_mode| for the values.
+ See |complete_info_mode| for the values.
pum_visible |TRUE| if popup menu is visible.
See |pumvisible()|.
items List of completion matches. Each item is a
@@ -4631,7 +4632,7 @@ gettabinfo([{arg}]) *gettabinfo()*
tabnr tab page number.
variables a reference to the dictionary with
tabpage-local variables
- windows List of |window-ID|s in the tag page.
+ windows List of |window-ID|s in the tab page.
gettabvar({tabnr}, {varname} [, {def}]) *gettabvar()*
Get the value of a tab-local variable {varname} in tab page
@@ -4769,6 +4770,9 @@ glob({expr} [, {nosuf} [, {list} [, {alllinks}]]]) *glob()*
If the expansion fails, the result is an empty String or List.
+ You can also use |readdir()| if you need to do complicated
+ things, such as limiting the number of matches.
+
A name for a non-existing file is not included. A symbolic
link is only included if it points to an existing file.
However, when the {alllinks} argument is present and it is
@@ -6341,8 +6345,7 @@ printf({fmt}, {expr1} ...) *printf()*
*printf-S*
S The text of the String argument is used. If a
precision is specified, no more display cells than the
- number specified are used. Without the |+multi_byte|
- feature works just like 's'.
+ number specified are used.
*printf-f* *E807*
f F The Float argument is converted into a string of the
@@ -6474,6 +6477,17 @@ readfile({fname} [, {binary} [, {max}]])
the result is an empty list.
Also see |writefile()|.
+ *readdir()*
+readdir({directory} [, {expr}])
+ Return a list with file and directory names in {directory}.
+ You can also use |glob()| if you don't need to do complicated
+ things, such as limiting the number of matches.
+
+ When {expr} is omitted all entries are included.
+ When {expr} is given, it is evaluated to check what to do:
+ If {expr} results in -1 then no further entries will
+ be handled.
+
reg_executing() *reg_executing()*
Returns the single letter name of the register being executed.
Returns an empty string when no register is being executed.
@@ -7990,10 +8004,10 @@ strcharpart({src}, {start} [, {len}]) *strcharpart()*
strdisplaywidth({expr} [, {col}]) *strdisplaywidth()*
The result is a Number, which is the number of display cells
- String {expr} occupies on the screen when it starts at {col}.
- When {col} is omitted zero is used. Otherwise it is the
- screen column where to start. This matters for Tab
- characters.
+ String {expr} occupies on the screen when it starts at {col}
+ (first column is zero). When {col} is omitted zero is used.
+ Otherwise it is the screen column where to start. This
+ matters for Tab characters.
The option settings of the current window are used. This
matters for anything that's displayed differently, such as
'tabstop' and 'display'.
diff --git a/runtime/doc/filetype.txt b/runtime/doc/filetype.txt
index a4a5d6188b..ad834e1f6c 100644
--- a/runtime/doc/filetype.txt
+++ b/runtime/doc/filetype.txt
@@ -599,6 +599,15 @@ your |vimrc|: >
let rrst_dynamic_comments = 0
+RESTRUCTUREDTEXT *ft-rst-plugin*
+
+The following formatting setting are optionally available: >
+ setlocal expandtab shiftwidth=3 softtabstop=3 tabstop=8
+
+To enable this behavior, set the following variable in your vimrc: >
+ let g:rst_style = 1
+
+
RPM SPEC *ft-spec-plugin*
Since the text for this plugin is rather long it has been put in a separate
diff --git a/runtime/doc/indent.txt b/runtime/doc/indent.txt
index 721aa93442..e69497e1ab 100644
--- a/runtime/doc/indent.txt
+++ b/runtime/doc/indent.txt
@@ -944,6 +944,11 @@ can sometimes be slow, thus it timeouts after 150 msec. If you notice the
indenting isn't correct, you can set a larger timeout in msec: >
let g:pyindent_searchpair_timeout = 500
+If looking back for unclosed parenthesis is still too slow, especially during
+a copy-paste operation, or if you don't need indenting inside multi-line
+parentheses, you can completely disable this feature: >
+ let g:pyindent_disable_parentheses_indenting = 1
+
R *ft-r-indent*
diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt
index 03523042c6..da48f7f84d 100644
--- a/runtime/doc/index.txt
+++ b/runtime/doc/index.txt
@@ -155,6 +155,20 @@ commands in CTRL-X submode *i_CTRL-X_index*
|i_CTRL-X_s| CTRL-X s spelling suggestions
{not available when compiled without the |+insert_expand| feature}
+commands in completion mode (see |popupmenu-keys|)
+
+|complete_CTRL-E| CTRL-E stop completion and go back to original text
+|complete_CTRL-Y| CTRL-Y accept selected match and stop completion
+ CTRL-L insert one character from the current match
+ <CR> insert currently selected match
+ <BS> delete one character and redo search
+ CTRL-H same as <BS>
+ <Up> select the previous match
+ <Down> select the next match
+ <PageUp> select a match several entries back
+ <PageDown> select a match several entries forward
+ other stop completion and insert the typed character
+
==============================================================================
2. Normal mode *normal-index*
@@ -555,6 +569,8 @@ tag command action in Normal mode ~
|CTRL-W_gF| CTRL-W g F edit file name under the cursor in a new
tab page and jump to the line number
following the file name.
+|CTRL-W_gt| CTRL-W g t same as `gt`: go to next tab page
+|CTRL-W_gT| CTRL-W g T same as `gT`: go to previous tab page
|CTRL-W_h| CTRL-W h go to Nth left window (stop at first window)
|CTRL-W_i| CTRL-W i split window and jump to declaration of
identifier under the cursor
@@ -840,6 +856,17 @@ tag char note action in Normal mode ~
|z<Right>| z<Right> same as "zl"
==============================================================================
+2.6 Operator-pending mode *operator-pending-index*
+
+These can be used after an operator, but before a {motion} has been entered.
+
+tag char action in Operator-pending mode ~
+-----------------------------------------------------------------------
+|o_v| v force operator to work characterwise
+|o_V| V force operator to work linewise
+|o_CTRL-V| CTRL-V force operator to work blockwise
+
+==============================================================================
3. Visual mode *visual-index*
Most commands in Visual mode are the same as in Normal mode. The ones listed
@@ -961,7 +988,7 @@ Normal characters are inserted at the current cursor position.
"Completion" below refers to context-sensitive completion. It will complete
file names, tags, commands etc. as appropriate.
-tag command action in Command-line editing mode ~
+tag command action in Command-line editing mode ~
------------------------------------------------------------------------------
CTRL-@ not used
|c_CTRL-A| CTRL-A do completion on the pattern in front of the
@@ -1001,10 +1028,11 @@ tag command action in Command-line editing mode ~
command-line from history.
|c_CTRL-Q| CTRL-Q same as CTRL-V, unless it's used for terminal
control flow
-|c_CTRL-R| CTRL-R {0-9a-z"%#*:= CTRL-F CTRL-P CTRL-W CTRL-A}
+|c_CTRL-R| CTRL-R {regname}
insert the contents of a register or object
under the cursor as if typed
-|c_CTRL-R_CTRL-R| CTRL-R CTRL-R {0-9a-z"%#*:= CTRL-F CTRL-P CTRL-W CTRL-A}
+|c_CTRL-R_CTRL-R| CTRL-R CTRL-R {regname}
+|c_CTRL-R_CTRL-O| CTRL-R CTRL-O {regname}
insert the contents of a register or object
under the cursor literally
CTRL-S (used for terminal control flow)
@@ -1060,7 +1088,7 @@ This is a brief but complete listing of all the ":" commands, without
mentioning any arguments. The optional part of the command name is inside [].
The commands are sorted on the non-optional part of their name.
-tag command action ~
+tag command action ~
------------------------------------------------------------------------------
|:!| :! filter lines or execute an external command
|:!!| :!! repeat last ":!" command
@@ -1468,7 +1496,8 @@ tag command action ~
|:sbrewind| :sbr[ewind] split window and go to first file in the
buffer list
|:scriptnames| :scr[iptnames] list names of all sourced Vim scripts
-|:scriptencoding| :scripte[ncoding] encoding used in sourced Vim script
+|:scriptencoding| :scripte[ncoding] encoding used in sourced Vim script
+|:scriptversion| :scriptv[ersion] version of Vim script used
|:scscope| :scs[cope] split window and execute cscope command
|:set| :se[t] show or set options
|:setfiletype| :setf[iletype] set 'filetype', unless it was set already
diff --git a/runtime/doc/message.txt b/runtime/doc/message.txt
index dccf39b3df..864eea8f7f 100644
--- a/runtime/doc/message.txt
+++ b/runtime/doc/message.txt
@@ -670,11 +670,13 @@ being disabled. Remove the 'C' flag from the 'cpoptions' option to enable it.
This happens when an Ex command with mandatory argument(s) was executed, but
no argument has been specified.
- *E474* *E475* >
+ *E474* *E475* *E983* >
Invalid argument
Invalid argument: {arg}
+ Duplicate argument: {arg}
-An Ex command has been executed, but an invalid argument has been specified.
+An Ex command or function has been executed, but an invalid argument has been
+specified.
*E488* >
Trailing characters
diff --git a/runtime/doc/motion.txt b/runtime/doc/motion.txt
index 461fefe903..818bbf9eb7 100644
--- a/runtime/doc/motion.txt
+++ b/runtime/doc/motion.txt
@@ -310,7 +310,7 @@ _ <underscore> [count] - 1 lines downward, on the first non-blank
G Goto line [count], default last line, on the first
non-blank character |linewise|. If 'startofline' not
set, keep the same column.
- G is a one of |jump-motions|.
+ G is one of the |jump-motions|.
*<C-End>*
<C-End> Goto line [count], default last line, on the last
@@ -989,7 +989,7 @@ These commands are not marks themselves, but jump to a mark:
A "jump" is a command that normally moves the cursor several lines away. If
you make the cursor "jump" the position of the cursor before the jump is
-remembered. You can return to that position with the "''" and "``" command,
+remembered. You can return to that position with the "''" and "``" commands,
unless the line containing that position was changed or deleted. The
following commands are "jump" commands: "'", "`", "G", "/", "?", "n", "N",
"%", "(", ")", "[[", "]]", "{", "}", ":s", ":tag", "L", "M", "H" and the
diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt
index d0ead3c256..a206bec44e 100644
--- a/runtime/doc/options.txt
+++ b/runtime/doc/options.txt
@@ -324,9 +324,9 @@ Setting the filetype
When the optional FALLBACK argument is present, a
later :setfiletype command will override the
- 'filetype'. This is to used for filetype detections
- that are just a guess. |did_filetype()| will return
- false after this command.
+ 'filetype'. This is to be used for filetype
+ detections that are just a guess. |did_filetype()|
+ will return false after this command.
*option-window* *optwin*
:bro[wse] se[t] *:set-browse* *:browse-set* *:opt* *:options*
@@ -1810,7 +1810,16 @@ A jump table for the options with a short description can be found at |Q_op|.
The default value is for C programs. For C++ this value would be
useful, to include const type declarations: >
^\(#\s*define\|[a-z]*\s*const\s*[a-z]*\)
+< You can also use "\ze" just before the name and continue the pattern
+ to check what is following. E.g. for Javascript, if a function is
+ defined with "func_name = function(args)": >
+ ^\s*\ze\i\+\s*=\s*function(
+< If the function is defined with "func_name : function() {...": >
+ ^\s*\ze\i\+\s*[:]\s*(*function\s*(
< When using the ":set" command, you need to double the backslashes!
+ To avoid that use `:let` with a single quote string: >
+ let &l:define = '^\s*\ze\k\+\s*=\s*function('
+<
*'delcombine'* *'deco'* *'nodelcombine'* *'nodeco'*
'delcombine' 'deco' boolean (default off)
@@ -1880,6 +1889,9 @@ A jump table for the options with a short description can be found at |Q_op|.
context:{n} Use a context of {n} lines between a change
and a fold that contains unchanged lines.
When omitted a context of six lines is used.
+ When using zero the context is actually one,
+ since folds require a line in between, also
+ for a deleted line.
See |fold-diff|.
iblank Ignore changes where lines are all blank. Adds
@@ -5331,7 +5343,8 @@ A jump table for the options with a short description can be found at |Q_op|.
O message for reading a file overwrites any previous message.
Also for quickfix message (e.g., ":cn").
s don't give "search hit BOTTOM, continuing at TOP" or "search
- hit TOP, continuing at BOTTOM" messages
+ hit TOP, continuing at BOTTOM" messages; when using the search
+ count do not show "W" after the count message (see S below)
t truncate file message at the start if it is too long to fit
on the command-line, "<" will appear in the left most column.
Ignored in Ex mode.
@@ -5603,7 +5616,8 @@ A jump table for the options with a short description can be found at |Q_op|.
set spelllang=en_us,nl,medical
< This means US English, Dutch and medical words are recognized. Words
that are not recognized will be highlighted.
- The word list name must not include a comma or dot. Using a dash is
+ The word list name must consist of alphanumeric characters, a dash or
+ an underscore. It should not include a comma or dot. Using a dash is
recommended to separate the two letter language name from a
specification. Thus "en-rare" is used for rare English words.
A region name must come last and have the form "_xx", where "xx" is
@@ -5971,7 +5985,9 @@ A jump table for the options with a short description can be found at |Q_op|.
pages.
split If included, split the current window before loading
a buffer for a |quickfix| command that display errors.
- Otherwise: do not split, use current window.
+ Otherwise: do not split, use current window (when used
+ in the quickfix window: the previously used window or
+ split if there is no other window).
vsplit Just like "split" but split vertically.
newtab Like "split", but open a new tab page. Overrules
"split" when both are present.
diff --git a/runtime/doc/pattern.txt b/runtime/doc/pattern.txt
index 5d2c0e97b8..7f6a74e3f6 100644
--- a/runtime/doc/pattern.txt
+++ b/runtime/doc/pattern.txt
@@ -1125,7 +1125,7 @@ x A single character, with no special meaning, matches itself
The "Func" column shows what library function is used. The
implementation depends on the system. Otherwise:
(1) Uses islower() for ASCII and Vim builtin rules for other
- characters when built with the |+multi_byte| feature.
+ characters.
(2) Uses Vim builtin rules
(3) As with (1) but using isupper()
*/[[=* *[==]*
@@ -1201,7 +1201,7 @@ x A single character, with no special meaning, matches itself
\%u20AC Matches the character specified with up to four hexadecimal
characters.
\%U1234abcd Matches the character specified with up to eight hexadecimal
- characters.
+ characters, up to 0x7fffffff
==============================================================================
7. Ignoring case in a pattern */ignorecase*
diff --git a/runtime/doc/pi_netrw.txt b/runtime/doc/pi_netrw.txt
index a0e071d4dd..95726324ef 100644
--- a/runtime/doc/pi_netrw.txt
+++ b/runtime/doc/pi_netrw.txt
@@ -3433,7 +3433,7 @@ Example: Clear netrw's marked file list via a mapping on gu >
- Click "Add..."
- Set External Editor (adjust path as needed, include
the quotes and !.! at the end):
- "c:\Program Files\Vim\vim70\gvim.exe" !.!
+ "c:\Program Files\Vim\vim81\gvim.exe" !.!
- Check that the filetype in the box below is
{asterisk}.{asterisk} (all files), or whatever types
you want (cec: change {asterisk} to * ; I had to
@@ -3683,8 +3683,8 @@ by obtaining a copy of the latest (often developmental) netrw at:
The <netrw.vim> script is typically installed on systems as something like:
>
- /usr/local/share/vim/vim7x/plugin/netrwPlugin.vim
- /usr/local/share/vim/vim7x/autoload/netrw.vim
+ /usr/local/share/vim/vim8x/plugin/netrwPlugin.vim
+ /usr/local/share/vim/vim8x/autoload/netrw.vim
(see output of :echo &rtp)
<
which is loaded automatically at startup (assuming :set nocp). If you
diff --git a/runtime/doc/print.txt b/runtime/doc/print.txt
index 084ad4e521..b6d781c1ca 100644
--- a/runtime/doc/print.txt
+++ b/runtime/doc/print.txt
@@ -99,10 +99,9 @@ not recognized by Vim will just be converted to lower case and underscores
replaced with '-' signs.
If 'printencoding' is empty or Vim cannot find the file then it will use
-'encoding' (if Vim is compiled with |+multi_byte| and it is set an 8-bit
-encoding) to find the print character encoding file. If Vim is unable to find
-a character encoding file then it will use the "latin1" print character
-encoding file.
+'encoding' (if it is set an 8-bit encoding) to find the print character
+encoding file. If Vim is unable to find a character encoding file then it
+will use the "latin1" print character encoding file.
When 'encoding' is set to a multi-byte encoding, Vim will try to convert
characters to the printing encoding for printing (if 'printencoding' is empty
@@ -238,9 +237,9 @@ possible. The following tables show the valid combinations:
Japanese JIS_C_1978 x x
JIS_X_1983 x x
JIS_X_1990 x x x
- MSWINDOWS x
- KANJITALK6 x
- KANJITALK7 x
+ MSWINDOWS x
+ KANJITALK6 x
+ KANJITALK7 x
euc-kr cp949 ucs-2 utf-8 ~
Korean KS_X_1992 x
diff --git a/runtime/doc/russian.txt b/runtime/doc/russian.txt
index 724c4f9454..776630a52b 100644
--- a/runtime/doc/russian.txt
+++ b/runtime/doc/russian.txt
@@ -52,8 +52,7 @@ automatic installs. Vim also needs to be compiled with |+gettext| feature for
user interface items translations to work.
After downloading an archive from RuVim project, unpack it into your
-$VIMRUNTIME directory. We recommend using UTF-8 archive, if your version of
-Vim is compiled with |+multi_byte| feature enabled.
+$VIMRUNTIME directory. We recommend using UTF-8 archive.
In order to use the Russian documentation, make sure you have set the
'helplang' option to "ru".
diff --git a/runtime/doc/spell.txt b/runtime/doc/spell.txt
index 67917d9617..955861bd2d 100644
--- a/runtime/doc/spell.txt
+++ b/runtime/doc/spell.txt
@@ -298,25 +298,25 @@ Exceptions:
spell file is used.
For example, with these values:
- 'runtimepath' is "~/.config/nvim,/usr/share/vim70,~/.config/nvim/after"
+ 'runtimepath' is "~/.config/nvim,/usr/local/share/nvim/runtime/,~/.config/nvim/after"
'encoding' is "iso-8859-2"
'spelllang' is "pl"
Vim will look for:
1. ~/.config/nvim/spell/pl.iso-8859-2.spl
-2. /usr/share/vim70/spell/pl.iso-8859-2.spl
+2. /usr/local/share/nvim/runtime/spell/pl.iso-8859-2.spl
3. ~/.config/nvim/spell/pl.iso-8859-2.add.spl
-4. /usr/share/vim70/spell/pl.iso-8859-2.add.spl
+4. /usr/local/share/nvim/runtime/spell/pl.iso-8859-2.add.spl
5. ~/.config/nvim/after/spell/pl.iso-8859-2.add.spl
This assumes 1. is not found and 2. is found.
If 'encoding' is "latin1" Vim will look for:
1. ~/.config/nvim/spell/pl.latin1.spl
-2. /usr/share/vim70/spell/pl.latin1.spl
+2. /usr/local/share/nvim/runtime/spell/pl.latin1.spl
3. ~/.config/nvim/after/spell/pl.latin1.spl
4. ~/.config/nvim/spell/pl.ascii.spl
-5. /usr/share/vim70/spell/pl.ascii.spl
+5. /usr/local/share/nvim/runtime/spell/pl.ascii.spl
6. ~/.config/nvim/after/spell/pl.ascii.spl
This assumes none of them are found (Polish doesn't make sense when leaving
diff --git a/runtime/doc/tagsrch.txt b/runtime/doc/tagsrch.txt
index f63535af11..4890cf3848 100644
--- a/runtime/doc/tagsrch.txt
+++ b/runtime/doc/tagsrch.txt
@@ -523,8 +523,7 @@ only supported by new versions of ctags (such as Exuberant ctags).
be any identifier. It cannot contain a <Tab>.
{TAB} One <Tab> character. Note: previous versions allowed any
white space here. This has been abandoned to allow spaces in
- {tagfile}. It can be re-enabled by including the
- |+tag_any_white| feature at compile time. *tag-any-white*
+ {tagfile}.
{tagfile} The file that contains the definition of {tagname}. It can
have an absolute or relative path. It may contain environment
variables and wildcards (although the use of wildcards is
@@ -572,8 +571,7 @@ ignored. (Case is ignored when 'ignorecase' is set and 'tagcase' is
The value '2' should be used then:
!_TAG_FILE_SORTED<Tab>2<Tab>{anything} ~
-The other tag that Vim recognizes, but only when compiled with the
-|+multi_byte| feature, is the encoding of the tags file:
+The other tag that Vim recognizes is the encoding of the tags file:
!_TAG_FILE_ENCODING<Tab>utf-8<Tab>{anything} ~
Here "utf-8" is the encoding used for the tags. Vim will then convert the tag
being searched for from 'encoding' to the encoding of the tags file. And when
diff --git a/runtime/doc/usr_05.txt b/runtime/doc/usr_05.txt
index d85be4ccae..e21481af17 100644
--- a/runtime/doc/usr_05.txt
+++ b/runtime/doc/usr_05.txt
@@ -192,7 +192,7 @@ typing commands at the command-line.
\ | wincmd p | diffthis
This adds the ":DiffOrig" command. Use this in a modified buffer to see the
-differences with the file it was loaded from. See |diff|.
+differences with the file it was loaded from. See |diff| and |:DiffOrig|.
>
set nolangremap
diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt
index 2c38c6fef2..a80ab963b1 100644
--- a/runtime/doc/usr_41.txt
+++ b/runtime/doc/usr_41.txt
@@ -770,6 +770,7 @@ System functions and manipulation of files:
systemlist() get the result of a shell command as a list
hostname() name of the system
readfile() read a file into a List of lines
+ readdir() get a List of file names in a directory
writefile() write a List of lines or Blob into a file
Date and Time: *date-functions* *time-functions*
diff --git a/runtime/doc/usr_45.txt b/runtime/doc/usr_45.txt
index be33f0be6d..1ce6969d37 100644
--- a/runtime/doc/usr_45.txt
+++ b/runtime/doc/usr_45.txt
@@ -152,12 +152,6 @@ language than the text.
language, the default should work fine and you don't need to do anything. The
following is only relevant when you want to edit different languages.
- Note:
- Using different encodings only works when Vim was compiled to handle
- it. To find out if it works, use the ":version" command and check the
- output for "+multi_byte". If it's there, you are OK. If you see
- "-multi_byte" you will have to find another Vim.
-
USING UNICODE IN THE GUI
diff --git a/runtime/doc/vi_diff.txt b/runtime/doc/vi_diff.txt
index d908f484c6..beecca2480 100644
--- a/runtime/doc/vi_diff.txt
+++ b/runtime/doc/vi_diff.txt
@@ -179,6 +179,12 @@ Command-line editing and history. |cmdline-editing|
forward/backward one character. The shifted right/left cursor keys
can be used to move forward/backward one word. CTRL-B/CTRL-E can be
used to go to the begin/end of the command-line.
+ {Vi: can only alter the last character in the line}
+ {Vi: when hitting <Esc> the command-line is executed. This is
+ unexpected for most people; therefore it was changed in Vim. But when
+ the <Esc> is part of a mapping, the command-line is executed. If you
+ want the Vi behaviour also when typing <Esc>, use ":cmap ^V<Esc>
+ ^V^M"}
|cmdline-history|
The command-lines are remembered. The up/down cursor keys can be used
to recall previous command-lines. The 'history' option can be set to
diff --git a/runtime/doc/visual.txt b/runtime/doc/visual.txt
index 252a1ca8b8..2062696a4e 100644
--- a/runtime/doc/visual.txt
+++ b/runtime/doc/visual.txt
@@ -103,6 +103,8 @@ gn Search forward for the last used search pattern, like
E.g., "dgn" deletes the text of the next match.
If Visual mode is active, extends the selection
until the end of the next match.
+ Note: Unlike `n` the search direction does not depend
+ on the previous search command.
*gN* *v_gN*
gN Like |gn| but searches backward, like with `N`.
diff --git a/runtime/doc/windows.txt b/runtime/doc/windows.txt
index ac9e1f48fe..b93945a340 100644
--- a/runtime/doc/windows.txt
+++ b/runtime/doc/windows.txt
@@ -807,6 +807,12 @@ CTRL-W gF *CTRL-W_gF*
{not available when the |+file_in_path| feature was disabled
at compile time}
+CTRL-W gt *CTRL-W_gt*
+ Go to next tab page, same as `gt`.
+
+CTRL-W gT *CTRL-W_gT*
+ Go to previous tab page, same as `gT`.
+
Also see |CTRL-W_CTRL-I|: open window for an included file that includes
the keyword under the cursor.
diff --git a/runtime/filetype.vim b/runtime/filetype.vim
index 9c92023e93..6504f610a0 100644
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -1,7 +1,7 @@
" Vim support file to detect file types
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
-" Last Change: 2019 Jan 28
+" Last Change: 2019 May 06
" Listen very carefully, I will say this only once
if exists("did_load_filetypes")
@@ -42,6 +42,8 @@ endif
" Function used for patterns that end in a star: don't set the filetype if the
" file name matches ft_ignore_pat.
+" When using this, the entry should probably be further down below with the
+" other StarSetf() calls.
func! s:StarSetf(ft)
if expand("<amatch>") !~ g:ft_ignore_pat
exe 'setf ' . a:ft
@@ -54,6 +56,9 @@ au BufNewFile,BufRead $VIMRUNTIME/doc/*.txt setf help
" Abaqus or Trasys
au BufNewFile,BufRead *.inp call dist#ft#Check_inp()
+" 8th (Firth-derivative)
+au BufNewFile,BufRead *.8th setf 8th
+
" A-A-P recipe
au BufNewFile,BufRead *.aap setf aap
@@ -88,9 +93,6 @@ au BufNewFile,BufRead build.xml setf ant
" Arduino
au BufNewFile,BufRead *.ino,*.pde setf arduino
-" Apache style config file
-au BufNewFile,BufRead proftpd.conf* call s:StarSetf('apachestyle')
-
" Apache config file
au BufNewFile,BufRead .htaccess,*/etc/httpd/*.conf setf apache
au BufNewFile,BufRead */etc/apache2/sites-*/*.com setf apache
@@ -648,7 +650,6 @@ au BufNewFile,BufRead gnashrc,.gnashrc,gnashpluginrc,.gnashpluginrc setf gnash
" Gitolite
au BufNewFile,BufRead gitolite.conf setf gitolite
-au BufNewFile,BufRead */gitolite-admin/conf/* call s:StarSetf('gitolite')
au BufNewFile,BufRead {,.}gitolite.rc,example.gitolite.rc setf perl
" Gnuplot scripts
@@ -797,7 +798,6 @@ au BufNewFile,BufRead *.jsp setf jsp
" Java Properties resource file (note: doesn't catch font.properties.pl)
au BufNewFile,BufRead *.properties,*.properties_??,*.properties_??_?? setf jproperties
-au BufNewFile,BufRead *.properties_??_??_* call s:StarSetf('jproperties')
" Jess
au BufNewFile,BufRead *.clp setf jess
@@ -1455,7 +1455,6 @@ au BufNewFile,BufRead *.decl,*.dcl,*.dec
" SGML catalog file
au BufNewFile,BufRead catalog setf catalog
-au BufNewFile,BufRead sgml.catalog* call s:StarSetf('catalog')
" Shell scripts (sh, ksh, bash, bash2, csh); Allow .profile_foo etc.
" Gentoo ebuilds and Arch Linux PKGBUILDs are actually bash scripts
@@ -1610,6 +1609,10 @@ au BufNewFile,BufRead */etc/sysctl.conf,*/etc/sysctl.d/*.conf setf sysctl
" Systemd unit files
au BufNewFile,BufRead */systemd/*.{automount,mount,path,service,socket,swap,target,timer} setf systemd
+" Systemd overrides
+au BufNewFile,BufRead /etc/systemd/system/*.d/*.conf setf systemd
+" Systemd temp files
+au BufNewFile,BufRead /etc/systemd/system/*.d/.#* setf systemd
" Synopsys Design Constraints
au BufNewFile,BufRead *.sdc setf sdc
@@ -1738,7 +1741,6 @@ au BufNewFile,BufRead *.sv,*.svh setf systemverilog
" VHDL
au BufNewFile,BufRead *.hdl,*.vhd,*.vhdl,*.vbe,*.vst setf vhdl
-au BufNewFile,BufRead *.vhdl_[0-9]* call s:StarSetf('vhdl')
" Vim script
au BufNewFile,BufRead *.vim,*.vba,.exrc,_exrc setf vim
@@ -1951,6 +1953,7 @@ au StdinReadPost * if !did_filetype() | runtime! scripts.vim | endif
" More Apache style config files
au BufNewFile,BufRead */etc/proftpd/*.conf*,*/etc/proftpd/conf.*/* call s:StarSetf('apachestyle')
+au BufNewFile,BufRead proftpd.conf* call s:StarSetf('apachestyle')
" More Apache config files
au BufNewFile,BufRead access.conf*,apache.conf*,apache2.conf*,httpd.conf*,srm.conf* call s:StarSetf('apache')
@@ -2007,6 +2010,12 @@ au BufNewFile,BufRead *fvwm2rc*
" Gedcom
au BufNewFile,BufRead */tmp/lltmp* call s:StarSetf('gedcom')
+" Git
+au BufNewFile,BufRead */.gitconfig.d/*,/etc/gitconfig.d/* call s:StarSetf('gitconfig')
+
+" Gitolite
+au BufNewFile,BufRead */gitolite-admin/conf/* call s:StarSetf('gitolite')
+
" GTK RC
au BufNewFile,BufRead .gtkrc*,gtkrc* call s:StarSetf('gtkrc')
@@ -2019,6 +2028,9 @@ au! BufNewFile,BufRead *jarg*
\| call s:StarSetf('jargon')
\|endif
+" Java Properties resource file (note: doesn't catch font.properties.pl)
+au BufNewFile,BufRead *.properties_??_??_* call s:StarSetf('jproperties')
+
" Kconfig
au BufNewFile,BufRead Kconfig.* call s:StarSetf('kconfig')
@@ -2080,6 +2092,9 @@ au BufRead,BufNewFile *.rdf call dist#ft#Redif()
" Remind
au BufNewFile,BufRead .reminders* call s:StarSetf('remind')
+" SGML catalog file
+au BufNewFile,BufRead sgml.catalog* call s:StarSetf('catalog')
+
" Shell scripts ending in a star
au BufNewFile,BufRead .bashrc*,.bash[_-]profile*,.bash[_-]logout*,.bash[_-]aliases*,bash-fc[-.]*,,PKGBUILD* call dist#ft#SetFileTypeSH("bash")
au BufNewFile,BufRead .kshrc* call dist#ft#SetFileTypeSH("ksh")
@@ -2091,6 +2106,9 @@ au BufNewFile,BufRead .tcshrc* call dist#ft#SetFileTypeShell("tcsh")
" csh scripts ending in a star
au BufNewFile,BufRead .login*,.cshrc* call dist#ft#CSH()
+" VHDL
+au BufNewFile,BufRead *.vhdl_[0-9]* call s:StarSetf('vhdl')
+
" Vim script
au BufNewFile,BufRead *vimrc* call s:StarSetf('vim')
diff --git a/runtime/ftplugin/8th.vim b/runtime/ftplugin/8th.vim
new file mode 100644
index 0000000000..14301187d6
--- /dev/null
+++ b/runtime/ftplugin/8th.vim
@@ -0,0 +1,25 @@
+" Vim ftplugin file
+" Language: 8th
+" Version: any
+" Last Change: 2015/11/08
+" Maintainer: Ron Aaron <ron@aaron-tech.com>
+" URL: https://8th-dev.com/
+" Filetypes: *.8th
+" NOTE: 8th allows any non-whitespace in a name, so you need to do:
+" setlocal iskeyword=!,@,33-35,%,$,38-64,A-Z,91-96,a-z,123-126,128-255
+" This goes with the syntax/8th.vim file.
+
+" Only do this when not done yet for this buffer
+if exists("b:did_8thplugin")
+ finish
+endif
+
+" Don't load another plugin for this buffer
+let b:did_8thplugin = 1
+
+setlocal ts=2 sts=2 sw=2 et
+setlocal com=s1:/*,mb:*,ex:*/,:\|,:\\
+setlocal fo=tcrqol
+setlocal matchpairs+=\::;
+setlocal iskeyword=!,@,33-35,%,$,38-64,A-Z,91-96,a-z,123-126,128-255
+setlocal suffixesadd=.8th
diff --git a/runtime/ftplugin/cobol.vim b/runtime/ftplugin/cobol.vim
index 11ad3ad727..d96a1bf281 100644
--- a/runtime/ftplugin/cobol.vim
+++ b/runtime/ftplugin/cobol.vim
@@ -1,7 +1,8 @@
" Vim filetype plugin file
" Language: cobol
-" Author: Tim Pope <vimNOSPAM@tpope.info>
-" Last Update: By ZyX: use shiftwidth()
+" Maintainer: Ankit Jain <ajatkj@yahoo.co.in>
+" (formerly Tim Pope <vimNOSPAM@tpope.info>)
+" Last Update: By Ankit Jain (changed maintainer) on 22.03.2019
" Insert mode mappings: <C-T> <C-D> <Tab>
" Normal mode mappings: < > << >> [[ ]] [] ][
diff --git a/runtime/ftplugin/dosbatch.vim b/runtime/ftplugin/dosbatch.vim
index dbc02d80f8..070bdc4ba2 100644
--- a/runtime/ftplugin/dosbatch.vim
+++ b/runtime/ftplugin/dosbatch.vim
@@ -1,7 +1,7 @@
" Vim filetype plugin file
" Language: MS-DOS .bat files
" Maintainer: Mike Williams <mrw@eandem.co.uk>
-" Last Change: 8th May 2012
+" Last Change: 14th April 2019
" Only do this when not done yet for this buffer
if exists("b:did_ftplugin")
@@ -16,6 +16,7 @@ set cpo&vim
" BAT comment formatting
setlocal comments=b:rem,b:@rem,b:REM,b:@REM,:::
+setlocal commentstring=::\ %s
setlocal formatoptions-=t formatoptions+=rol
" Define patterns for the browse file filter
diff --git a/runtime/ftplugin/make.vim b/runtime/ftplugin/make.vim
index fb180c0e5f..bfa8703082 100644
--- a/runtime/ftplugin/make.vim
+++ b/runtime/ftplugin/make.vim
@@ -1,7 +1,7 @@
" Vim filetype plugin file
" Language: Make
" Maintainer: Bram Moolenaar <Bram@vim.org>
-" Last Change: 2013 Apr 22
+" Last Change: 2019 Apr 02
" Only do this when not done yet for this buffer
if exists("b:did_ftplugin")
@@ -27,7 +27,7 @@ setlocal commentstring=#\ %s
" Including files.
let &l:include = '^\s*include'
-" For matchit.vim, suggested by Albert Netymk.
+" For matchit.vim, suggested by Albert Netymk and Ken Takata.
if exists("loaded_matchit")
- let b:match_words = '\<if\(n\)\=\(eq\|def\)\>:\<else\>:\<endif\>,\<define\>:\<endef\>'
+ let b:match_words = '^ *ifn\=\(eq\|def\)\>:^ *else\(\s\+ifn\=\(eq\|def\)\)\=\>:^ *endif\>,\<define\>:\<endef\>,^!\s*if\(n\=def\)\=\>:^!\s*else\(if\(n\=def\)\=\)\=\>:^!\s*endif\>'
endif
diff --git a/runtime/ftplugin/nroff.vim b/runtime/ftplugin/nroff.vim
new file mode 100644
index 0000000000..069c02e59a
--- /dev/null
+++ b/runtime/ftplugin/nroff.vim
@@ -0,0 +1,11 @@
+" Vim filetype plugin
+" Language: roff(7)
+" Maintainer: Chris Spiegel <cspiegel@gmail.com>
+" Last Change: 2019 Apr 24
+
+if exists("b:did_ftplugin")
+ finish
+endif
+let b:did_ftplugin = 1
+
+setlocal commentstring=.\\\"%s
diff --git a/runtime/ftplugin/ocaml.vim b/runtime/ftplugin/ocaml.vim
index e0d7efe997..d9336421cf 100644
--- a/runtime/ftplugin/ocaml.vim
+++ b/runtime/ftplugin/ocaml.vim
@@ -392,8 +392,8 @@ endfunction
endfun
" This variable contain a dictionnary of list. Each element of the dictionnary
- " represent an annotation system. An annotation system is a list with :
- " - annotation file name as it's key
+ " represent an annotation system. An annotation system is a list with:
+ " - annotation file name as its key
" - annotation file path as first element of the contained list
" - build path as second element of the contained list
" - annot_file_last_mod (contain the date of .annot file) as third element
diff --git a/runtime/ftplugin/python.vim b/runtime/ftplugin/python.vim
index 5c4a59b1a9..64c1a87a69 100644
--- a/runtime/ftplugin/python.vim
+++ b/runtime/ftplugin/python.vim
@@ -3,7 +3,7 @@
" Maintainer: Tom Picton <tom@tompicton.co.uk>
" Previous Maintainer: James Sully <sullyj3@gmail.com>
" Previous Maintainer: Johannes Zellner <johannes@zellner.org>
-" Last Change: Sun, 15 April 2018
+" Last Change: Sun 17 Mar 2019
" https://github.com/tpict/vim-ftplugin-python
if exists("b:did_ftplugin") | finish | endif
@@ -37,9 +37,10 @@ setlocal suffixesadd=.py
setlocal comments=b:#,fb:-
setlocal commentstring=#\ %s
-setlocal omnifunc=pythoncomplete#Complete
if has('python3')
- setlocal omnifunc=python3complete#Complete
+ setlocal omnifunc=python3complete#Complete
+elseif has('python')
+ setlocal omnifunc=pythoncomplete#Complete
endif
set wildignore+=*.pyc
@@ -53,32 +54,34 @@ let b:prev='\v^\s*(class\|def\|async def)>'
let b:next_end='\v\S\n*(%$\|^(\s*\n*)*(class\|def\|async def)\|^\S)'
let b:prev_end='\v\S\n*(^(\s*\n*)*(class\|def\|async def)\|^\S)'
-execute "nnoremap <silent> <buffer> ]] :call <SID>Python_jump('n', '". b:next_toplevel."', 'W', v:count1)<cr>"
-execute "nnoremap <silent> <buffer> [[ :call <SID>Python_jump('n', '". b:prev_toplevel."', 'Wb', v:count1)<cr>"
-execute "nnoremap <silent> <buffer> ][ :call <SID>Python_jump('n', '". b:next_endtoplevel."', 'W', 0, v:count1)<cr>"
-execute "nnoremap <silent> <buffer> [] :call <SID>Python_jump('n', '". b:prev_endtoplevel."', 'Wb', 0, v:count1)<cr>"
-execute "nnoremap <silent> <buffer> ]m :call <SID>Python_jump('n', '". b:next."', 'W', v:count1)<cr>"
-execute "nnoremap <silent> <buffer> [m :call <SID>Python_jump('n', '". b:prev."', 'Wb', v:count1)<cr>"
-execute "nnoremap <silent> <buffer> ]M :call <SID>Python_jump('n', '". b:next_end."', 'W', 0, v:count1)<cr>"
-execute "nnoremap <silent> <buffer> [M :call <SID>Python_jump('n', '". b:prev_end."', 'Wb', 0, v:count1)<cr>"
-
-execute "onoremap <silent> <buffer> ]] :call <SID>Python_jump('o', '". b:next_toplevel."', 'W', v:count1)<cr>"
-execute "onoremap <silent> <buffer> [[ :call <SID>Python_jump('o', '". b:prev_toplevel."', 'Wb', v:count1)<cr>"
-execute "onoremap <silent> <buffer> ][ :call <SID>Python_jump('o', '". b:next_endtoplevel."', 'W', 0, v:count1)<cr>"
-execute "onoremap <silent> <buffer> [] :call <SID>Python_jump('o', '". b:prev_endtoplevel."', 'Wb', 0, v:count1)<cr>"
-execute "onoremap <silent> <buffer> ]m :call <SID>Python_jump('o', '". b:next."', 'W', v:count1)<cr>"
-execute "onoremap <silent> <buffer> [m :call <SID>Python_jump('o', '". b:prev."', 'Wb', v:count1)<cr>"
-execute "onoremap <silent> <buffer> ]M :call <SID>Python_jump('o', '". b:next_end."', 'W', 0, v:count1)<cr>"
-execute "onoremap <silent> <buffer> [M :call <SID>Python_jump('o', '". b:prev_end."', 'Wb', 0, v:count1)<cr>"
-
-execute "xnoremap <silent> <buffer> ]] :call <SID>Python_jump('x', '". b:next_toplevel."', 'W', v:count1)<cr>"
-execute "xnoremap <silent> <buffer> [[ :call <SID>Python_jump('x', '". b:prev_toplevel."', 'Wb', v:count1)<cr>"
-execute "xnoremap <silent> <buffer> ][ :call <SID>Python_jump('x', '". b:next_endtoplevel."', 'W', 0, v:count1)<cr>"
-execute "xnoremap <silent> <buffer> [] :call <SID>Python_jump('x', '". b:prev_endtoplevel."', 'Wb', 0, v:count1)<cr>"
-execute "xnoremap <silent> <buffer> ]m :call <SID>Python_jump('x', '". b:next."', 'W', v:count1)<cr>"
-execute "xnoremap <silent> <buffer> [m :call <SID>Python_jump('x', '". b:prev."', 'Wb', v:count1)<cr>"
-execute "xnoremap <silent> <buffer> ]M :call <SID>Python_jump('x', '". b:next_end."', 'W', 0, v:count1)<cr>"
-execute "xnoremap <silent> <buffer> [M :call <SID>Python_jump('x', '". b:prev_end."', 'Wb', 0, v:count1)<cr>"
+if !exists('g:no_plugin_maps') && !exists('g:no_python_maps')
+ execute "nnoremap <silent> <buffer> ]] :call <SID>Python_jump('n', '". b:next_toplevel."', 'W', v:count1)<cr>"
+ execute "nnoremap <silent> <buffer> [[ :call <SID>Python_jump('n', '". b:prev_toplevel."', 'Wb', v:count1)<cr>"
+ execute "nnoremap <silent> <buffer> ][ :call <SID>Python_jump('n', '". b:next_endtoplevel."', 'W', v:count1, 0)<cr>"
+ execute "nnoremap <silent> <buffer> [] :call <SID>Python_jump('n', '". b:prev_endtoplevel."', 'Wb', v:count1, 0)<cr>"
+ execute "nnoremap <silent> <buffer> ]m :call <SID>Python_jump('n', '". b:next."', 'W', v:count1)<cr>"
+ execute "nnoremap <silent> <buffer> [m :call <SID>Python_jump('n', '". b:prev."', 'Wb', v:count1)<cr>"
+ execute "nnoremap <silent> <buffer> ]M :call <SID>Python_jump('n', '". b:next_end."', 'W', v:count1, 0)<cr>"
+ execute "nnoremap <silent> <buffer> [M :call <SID>Python_jump('n', '". b:prev_end."', 'Wb', v:count1, 0)<cr>"
+
+ execute "onoremap <silent> <buffer> ]] :call <SID>Python_jump('o', '". b:next_toplevel."', 'W', v:count1)<cr>"
+ execute "onoremap <silent> <buffer> [[ :call <SID>Python_jump('o', '". b:prev_toplevel."', 'Wb', v:count1)<cr>"
+ execute "onoremap <silent> <buffer> ][ :call <SID>Python_jump('o', '". b:next_endtoplevel."', 'W', v:count1, 0)<cr>"
+ execute "onoremap <silent> <buffer> [] :call <SID>Python_jump('o', '". b:prev_endtoplevel."', 'Wb', v:count1, 0)<cr>"
+ execute "onoremap <silent> <buffer> ]m :call <SID>Python_jump('o', '". b:next."', 'W', v:count1)<cr>"
+ execute "onoremap <silent> <buffer> [m :call <SID>Python_jump('o', '". b:prev."', 'Wb', v:count1)<cr>"
+ execute "onoremap <silent> <buffer> ]M :call <SID>Python_jump('o', '". b:next_end."', 'W', v:count1, 0)<cr>"
+ execute "onoremap <silent> <buffer> [M :call <SID>Python_jump('o', '". b:prev_end."', 'Wb', v:count1, 0)<cr>"
+
+ execute "xnoremap <silent> <buffer> ]] :call <SID>Python_jump('x', '". b:next_toplevel."', 'W', v:count1)<cr>"
+ execute "xnoremap <silent> <buffer> [[ :call <SID>Python_jump('x', '". b:prev_toplevel."', 'Wb', v:count1)<cr>"
+ execute "xnoremap <silent> <buffer> ][ :call <SID>Python_jump('x', '". b:next_endtoplevel."', 'W', v:count1, 0)<cr>"
+ execute "xnoremap <silent> <buffer> [] :call <SID>Python_jump('x', '". b:prev_endtoplevel."', 'Wb', v:count1, 0)<cr>"
+ execute "xnoremap <silent> <buffer> ]m :call <SID>Python_jump('x', '". b:next."', 'W', v:count1)<cr>"
+ execute "xnoremap <silent> <buffer> [m :call <SID>Python_jump('x', '". b:prev."', 'Wb', v:count1)<cr>"
+ execute "xnoremap <silent> <buffer> ]M :call <SID>Python_jump('x', '". b:next_end."', 'W', v:count1, 0)<cr>"
+ execute "xnoremap <silent> <buffer> [M :call <SID>Python_jump('x', '". b:prev_end."', 'Wb', v:count1, 0)<cr>"
+endif
if !exists('*<SID>Python_jump')
fun! <SID>Python_jump(mode, motion, flags, count, ...) range
@@ -123,10 +126,80 @@ if !exists('g:pydoc_executable')
let g:pydoc_executable = 0
endif
endif
+
+" Windows-specific pydoc setup
+if has('win32') || has('win64')
+ if executable('python')
+ " available as Tools\scripts\pydoc.py
+ let g:pydoc_executable = 1
+ else
+ let g:pydoc_executable = 0
+ endif
+endif
+
" If "pydoc" was found use it for keywordprg.
if g:pydoc_executable
- setlocal keywordprg=pydoc
+ if has('win32') || has('win64')
+ setlocal keywordprg=python\ -m\ pydoc\
+ else
+ setlocal keywordprg=pydoc
+ endif
endif
+" Script for filetype switching to undo the local stuff we may have changed
+let b:undo_ftplugin = 'setlocal cinkeys<'
+ \ . '|setlocal comments<'
+ \ . '|setlocal commentstring<'
+ \ . '|setlocal expandtab<'
+ \ . '|setlocal include<'
+ \ . '|setlocal includeexpr<'
+ \ . '|setlocal indentkeys<'
+ \ . '|setlocal keywordprg<'
+ \ . '|setlocal omnifunc<'
+ \ . '|setlocal shiftwidth<'
+ \ . '|setlocal softtabstop<'
+ \ . '|setlocal suffixesadd<'
+ \ . '|setlocal tabstop<'
+ \ . '|silent! nunmap <buffer> [M'
+ \ . '|silent! nunmap <buffer> [['
+ \ . '|silent! nunmap <buffer> []'
+ \ . '|silent! nunmap <buffer> [m'
+ \ . '|silent! nunmap <buffer> ]M'
+ \ . '|silent! nunmap <buffer> ]['
+ \ . '|silent! nunmap <buffer> ]]'
+ \ . '|silent! nunmap <buffer> ]m'
+ \ . '|silent! ounmap <buffer> [M'
+ \ . '|silent! ounmap <buffer> [['
+ \ . '|silent! ounmap <buffer> []'
+ \ . '|silent! ounmap <buffer> [m'
+ \ . '|silent! ounmap <buffer> ]M'
+ \ . '|silent! ounmap <buffer> ]['
+ \ . '|silent! ounmap <buffer> ]]'
+ \ . '|silent! ounmap <buffer> ]m'
+ \ . '|silent! xunmap <buffer> [M'
+ \ . '|silent! xunmap <buffer> [['
+ \ . '|silent! xunmap <buffer> []'
+ \ . '|silent! xunmap <buffer> [m'
+ \ . '|silent! xunmap <buffer> ]M'
+ \ . '|silent! xunmap <buffer> ]['
+ \ . '|silent! xunmap <buffer> ]]'
+ \ . '|silent! xunmap <buffer> ]m'
+ \ . '|unlet! b:browsefilter'
+ \ . '|unlet! b:child_match'
+ \ . '|unlet! b:child_sub'
+ \ . '|unlet! b:grandparent_match'
+ \ . '|unlet! b:grandparent_sub'
+ \ . '|unlet! b:next'
+ \ . '|unlet! b:next_end'
+ \ . '|unlet! b:next_endtoplevel'
+ \ . '|unlet! b:next_toplevel'
+ \ . '|unlet! b:parent_match'
+ \ . '|unlet! b:parent_sub'
+ \ . '|unlet! b:prev'
+ \ . '|unlet! b:prev_end'
+ \ . '|unlet! b:prev_endtoplevel'
+ \ . '|unlet! b:prev_toplevel'
+ \ . '|unlet! b:undo_ftplugin'
+
let &cpo = s:keepcpo
unlet s:keepcpo
diff --git a/runtime/ftplugin/rst.vim b/runtime/ftplugin/rst.vim
index 8ab56b052a..f0646e9f36 100644
--- a/runtime/ftplugin/rst.vim
+++ b/runtime/ftplugin/rst.vim
@@ -30,7 +30,7 @@ setlocal formatoptions+=tcroql
"
" More sophisticated indentation rules should be revisted in the future.
-if !exists("g:rst_style") || g:rst_style != 0
+if exists("g:rst_style") && g:rst_style != 0
setlocal expandtab shiftwidth=3 softtabstop=3 tabstop=8
endif
diff --git a/runtime/ftplugin/sql.vim b/runtime/ftplugin/sql.vim
index 4d6fcd9564..1c02a98c7c 100644
--- a/runtime/ftplugin/sql.vim
+++ b/runtime/ftplugin/sql.vim
@@ -400,7 +400,7 @@ endif
" Predefined SQL objects what are used by the below mappings using
" the ]} style maps.
-" This global variable allows the users to override it's value
+" This global variable allows the users to override its value
" from within their vimrc.
" Note, you cannot use \?, since these patterns can be used to search
" backwards, you must use \{,1}
@@ -486,10 +486,10 @@ if exists('&omnifunc')
" OMNI function prior to setting up the SQL OMNI function
let b:sql_compl_savefunc = &omnifunc
- " Source it to determine it's version
+ " Source it to determine its version
runtime autoload/sqlcomplete.vim
" This is used by the sqlcomplete.vim plugin
- " Source it for it's global functions
+ " Source it for its global functions
runtime autoload/syntaxcomplete.vim
setlocal omnifunc=sqlcomplete#Complete
diff --git a/runtime/indent/awk.vim b/runtime/indent/awk.vim
index aad73ee71f..e65331977c 100644
--- a/runtime/indent/awk.vim
+++ b/runtime/indent/awk.vim
@@ -47,7 +47,7 @@ endif
function! GetAwkIndent()
- " Find previous line and get it's indentation
+ " Find previous line and get its indentation
let prev_lineno = s:Get_prev_line( v:lnum )
if prev_lineno == 0
return 0
diff --git a/runtime/indent/cobol.vim b/runtime/indent/cobol.vim
index c08444ac40..590a729df4 100644
--- a/runtime/indent/cobol.vim
+++ b/runtime/indent/cobol.vim
@@ -1,7 +1,12 @@
" Vim indent file
" Language: cobol
-" Author: Tim Pope <vimNOSPAM@tpope.info>
+" Maintainer: Ankit Jain <ajatkj@yahoo.co.in>
+" (formerly Tim Pope <vimNOSPAM@tpope.info>)
" $Id: cobol.vim,v 1.1 2007/05/05 18:08:19 vimboss Exp $
+" Last Update: By Ankit Jain on 22.03.2019
+" Ankit Jain 22.03.2019 Changes & fixes:
+" Allow chars in 1st 6 columns
+" #C22032019
if exists("b:did_indent")
finish
@@ -66,7 +71,9 @@ function! GetCobolIndent(lnum) abort
let ashft = minshft + 1
let bshft = ashft + 4
" (Obsolete) numbered lines
- if getline(a:lnum) =~? '^\s*\d\{6\}\%($\|[ */$CD-]\)'
+ " #C22032019: Columns 1-6 could have alphabets as well as numbers
+ "if getline(a:lnum) =~? '^\s*\d\{6\}\%($\|[ */$CD-]\)'
+ if getline(a:lnum) =~? '^\s*[a-zA-Z0-9]\{6\}\%($\|[ */$CD-]\)'
return 0
endif
let cline = s:stripped(a:lnum)
diff --git a/runtime/indent/html.vim b/runtime/indent/html.vim
index 1a8177050a..1d2043ae9e 100644
--- a/runtime/indent/html.vim
+++ b/runtime/indent/html.vim
@@ -2,7 +2,7 @@
" Header: "{{{
" Maintainer: Bram Moolenaar
" Original Author: Andy Wokula <anwoku@yahoo.de>
-" Last Change: 2018 Mar 28
+" Last Change: 2019 Mar 20
" Version: 1.0
" Description: HTML indent script with cached state for faster indenting on a
" range of lines.
@@ -902,12 +902,19 @@ func! s:InsideTag(foundHtmlString)
"{{{
if a:foundHtmlString
" Inside an attribute string.
- " Align with the previous line or use an external function.
+ " Align with the opening quote or use an external function.
let lnum = v:lnum - 1
if lnum > 1
if exists('b:html_indent_tag_string_func')
return b:html_indent_tag_string_func(lnum)
endif
+ " If there is a double quote in the previous line, indent with the
+ " character after it.
+ if getline(lnum) =~ '"'
+ call cursor(lnum, 0)
+ normal f"
+ return virtcol('.')
+ endif
return indent(lnum)
endif
endif
diff --git a/runtime/indent/mma.vim b/runtime/indent/mma.vim
index 8298ad98cd..a76fa8ede0 100644
--- a/runtime/indent/mma.vim
+++ b/runtime/indent/mma.vim
@@ -57,7 +57,7 @@ function GetMmaIndent()
if getline(v:lnum) =~ '[^[]*]\s*$'
" move to the closing bracket
call search(']','bW')
- " and find it's partner's indent
+ " and find its partner's indent
let ind = indent(searchpair('\[','',']','bWn'))
" same for ( blocks
elseif getline(v:lnum) =~ '[^(]*)$'
diff --git a/runtime/indent/python.vim b/runtime/indent/python.vim
index 7ab3cb9f50..e53987a0de 100644
--- a/runtime/indent/python.vim
+++ b/runtime/indent/python.vim
@@ -2,7 +2,7 @@
" Language: Python
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Original Author: David Bustos <bustos@caltech.edu>
-" Last Change: 2013 Jul 9
+" Last Change: 2019 Feb 21
" Only load this indent file when no other was loaded.
if exists("b:did_indent")
@@ -53,58 +53,68 @@ function GetPythonIndent(lnum)
return 0
endif
- " searchpair() can be slow sometimes, limit the time to 100 msec or what is
- " put in g:pyindent_searchpair_timeout
- let searchpair_stopline = 0
- let searchpair_timeout = get(g:, 'pyindent_searchpair_timeout', 150)
-
- " If the previous line is inside parenthesis, use the indent of the starting
- " line.
- " Trick: use the non-existing "dummy" variable to break out of the loop when
- " going too far back.
call cursor(plnum, 1)
- let parlnum = searchpair('(\|{\|\[', '', ')\|}\|\]', 'nbW',
- \ "line('.') < " . (plnum - s:maxoff) . " ? dummy :"
- \ . " synIDattr(synID(line('.'), col('.'), 1), 'name')"
- \ . " =~ '\\(Comment\\|Todo\\|String\\)$'",
- \ searchpair_stopline, searchpair_timeout)
- if parlnum > 0
- let plindent = indent(parlnum)
- let plnumstart = parlnum
- else
+
+ " Identing inside parentheses can be very slow, regardless of the searchpair()
+ " timeout, so let the user disable this feature if he doesn't need it
+ let disable_parentheses_indenting = get(g:, "pyindent_disable_parentheses_indenting", 0)
+
+ if disable_parentheses_indenting == 1
let plindent = indent(plnum)
let plnumstart = plnum
- endif
-
+ else
+ " searchpair() can be slow sometimes, limit the time to 150 msec or what is
+ " put in g:pyindent_searchpair_timeout
+ let searchpair_stopline = 0
+ let searchpair_timeout = get(g:, 'pyindent_searchpair_timeout', 150)
+
+ " If the previous line is inside parenthesis, use the indent of the starting
+ " line.
+ " Trick: use the non-existing "dummy" variable to break out of the loop when
+ " going too far back.
+ let parlnum = searchpair('(\|{\|\[', '', ')\|}\|\]', 'nbW',
+ \ "line('.') < " . (plnum - s:maxoff) . " ? dummy :"
+ \ . " synIDattr(synID(line('.'), col('.'), 1), 'name')"
+ \ . " =~ '\\(Comment\\|Todo\\|String\\)$'",
+ \ searchpair_stopline, searchpair_timeout)
+ if parlnum > 0
+ let plindent = indent(parlnum)
+ let plnumstart = parlnum
+ else
+ let plindent = indent(plnum)
+ let plnumstart = plnum
+ endif
- " When inside parenthesis: If at the first line below the parenthesis add
- " two 'shiftwidth', otherwise same as previous line.
- " i = (a
- " + b
- " + c)
- call cursor(a:lnum, 1)
- let p = searchpair('(\|{\|\[', '', ')\|}\|\]', 'bW',
- \ "line('.') < " . (a:lnum - s:maxoff) . " ? dummy :"
- \ . " synIDattr(synID(line('.'), col('.'), 1), 'name')"
- \ . " =~ '\\(Comment\\|Todo\\|String\\)$'",
- \ searchpair_stopline, searchpair_timeout)
- if p > 0
- if p == plnum
- " When the start is inside parenthesis, only indent one 'shiftwidth'.
- let pp = searchpair('(\|{\|\[', '', ')\|}\|\]', 'bW',
- \ "line('.') < " . (a:lnum - s:maxoff) . " ? dummy :"
- \ . " synIDattr(synID(line('.'), col('.'), 1), 'name')"
- \ . " =~ '\\(Comment\\|Todo\\|String\\)$'",
- \ searchpair_stopline, searchpair_timeout)
- if pp > 0
- return indent(plnum) + (exists("g:pyindent_nested_paren") ? eval(g:pyindent_nested_paren) : shiftwidth())
+ " When inside parenthesis: If at the first line below the parenthesis add
+ " two 'shiftwidth', otherwise same as previous line.
+ " i = (a
+ " + b
+ " + c)
+ call cursor(a:lnum, 1)
+ let p = searchpair('(\|{\|\[', '', ')\|}\|\]', 'bW',
+ \ "line('.') < " . (a:lnum - s:maxoff) . " ? dummy :"
+ \ . " synIDattr(synID(line('.'), col('.'), 1), 'name')"
+ \ . " =~ '\\(Comment\\|Todo\\|String\\)$'",
+ \ searchpair_stopline, searchpair_timeout)
+ if p > 0
+ if p == plnum
+ " When the start is inside parenthesis, only indent one 'shiftwidth'.
+ let pp = searchpair('(\|{\|\[', '', ')\|}\|\]', 'bW',
+ \ "line('.') < " . (a:lnum - s:maxoff) . " ? dummy :"
+ \ . " synIDattr(synID(line('.'), col('.'), 1), 'name')"
+ \ . " =~ '\\(Comment\\|Todo\\|String\\)$'",
+ \ searchpair_stopline, searchpair_timeout)
+ if pp > 0
+ return indent(plnum) + (exists("g:pyindent_nested_paren") ? eval(g:pyindent_nested_paren) : shiftwidth())
+ endif
+ return indent(plnum) + (exists("g:pyindent_open_paren") ? eval(g:pyindent_open_paren) : (shiftwidth() * 2))
endif
- return indent(plnum) + (exists("g:pyindent_open_paren") ? eval(g:pyindent_open_paren) : (shiftwidth() * 2))
- endif
- if plnumstart == p
- return indent(plnum)
+ if plnumstart == p
+ return indent(plnum)
+ endif
+ return plindent
endif
- return plindent
+
endif
diff --git a/runtime/indent/rmd.vim b/runtime/indent/rmd.vim
index 182b07cbaa..83fe4e4fed 100644
--- a/runtime/indent/rmd.vim
+++ b/runtime/indent/rmd.vim
@@ -39,7 +39,7 @@ endfunction
function s:GetYamlIndent()
let pline = getline(v:lnum - 1)
if pline =~ ':\s*$'
- return indent(v:lnum) + &sw
+ return indent(v:lnum) + shiftwidth()
elseif pline =~ '^\s*- '
return indent(v:lnum) + 2
endif
diff --git a/runtime/indent/sh.vim b/runtime/indent/sh.vim
index c93be31958..148a86ed67 100644
--- a/runtime/indent/sh.vim
+++ b/runtime/indent/sh.vim
@@ -3,10 +3,18 @@
" Maintainer: Christian Brabandt <cb@256bit.org>
" Original Author: Nikolai Weibull <now@bitwi.se>
" Previous Maintainer: Peter Aronoff <telemachus@arpinum.org>
-" Latest Revision: 2019-02-02
+" Latest Revision: 2019-04-27
" License: Vim (see :h license)
" Repository: https://github.com/chrisbra/vim-sh-indent
" Changelog:
+" 20190428 - De-indent fi correctly when typing with
+" https://github.com/chrisbra/vim-sh-indent/issues/15
+" 20190325 - Indent fi; correctly
+" https://github.com/chrisbra/vim-sh-indent/issues/14
+" 20190319 - Indent arrays (only zsh and bash)
+" https://github.com/chrisbra/vim-sh-indent/issues/13
+" 20190316 - Make use of searchpairpos for nested if sections
+" fixes https://github.com/chrisbra/vim-sh-indent/issues/11
" 20190201 - Better check for closing if sections
" 20180724 - make check for zsh syntax more rigid (needs word-boundaries)
" 20180326 - better support for line continuation
@@ -86,6 +94,12 @@ function! GetShIndent()
if line !~ '}\s*\%(#.*\)\=$'
let ind += s:indent_value('default')
endif
+ " array (only works for zsh or bash)
+ elseif s:is_array(line) && line !~ ')\s*$' && (&ft is# 'zsh' || s:is_bash())
+ let ind += s:indent_value('continuation-line')
+ " end of array
+ elseif curline =~ '^\s*)$'
+ let ind -= s:indent_value('continuation-line')
elseif s:is_continuation_line(line)
if pnum == 0 || !s:is_continuation_line(pline)
let ind += s:indent_value('continuation-line')
@@ -114,8 +128,8 @@ function! GetShIndent()
let line = curline
" Current line is a endif line, so get indent from start of "if condition" line
" TODO: should we do the same for other "end" lines?
- if curline =~ '^\s*\%(fi\)\s*\%(#.*\)\=$'
- let previous_line = search('if.\{-\};\s*then\s*\%(#.*\)\=$', 'bnW')
+ if curline =~ '^\s*\%(fi\);\?\s*\%(#.*\)\=$'
+ let previous_line = searchpair('\<if\>', '', '\<fi\>\zs', 'bnW')
if previous_line > 0
let ind = indent(previous_line)
endif
@@ -179,6 +193,10 @@ function! s:is_function_definition(line)
\ a:line =~ '^\s*function\s*\w\S\+\s*\%(()\)\?\s*{'
endfunction
+function! s:is_array(line)
+ return a:line =~ '^\s*\<\k\+\>=('
+endfunction
+
function! s:is_case_label(line, pnum)
if a:line !~ '^\s*(\=.*)'
return 0
@@ -272,5 +290,9 @@ function! s:is_end_expression(line)
return a:line =~ '\<\%(fi\|esac\|done\|end\)\>\s*\%(#.*\)\=$'
endfunction
+function! s:is_bash()
+ return get(g:, 'is_bash', 0) || get(b:, 'is_bash', 0)
+endfunction
+
let &cpo = s:cpo_save
unlet s:cpo_save
diff --git a/runtime/indent/testdir/html.ok b/runtime/indent/testdir/html.ok
index 524d57bb6c..ad819333cc 100644
--- a/runtime/indent/testdir/html.ok
+++ b/runtime/indent/testdir/html.ok
@@ -9,17 +9,17 @@
</div>
<div
- class="foo bar">
+ class="foo bar">
text
</div>
<div class="foo bar"
- data="something">
+ data="something">
text
</div>
<div class="foo
- bar">
+ bar">
text
</div>
diff --git a/runtime/indent/testdir/xml.ok b/runtime/indent/testdir/xml.ok
index 529198572a..cfdf701c11 100644
--- a/runtime/indent/testdir/xml.ok
+++ b/runtime/indent/testdir/xml.ok
@@ -10,11 +10,11 @@
<!-- text comment -->
<!--
- text comment
+ text comment
-->
</tag1>
<!--
- text comment
+ text comment
end coment -->
</tag0>
<!-- END_INDENT -->
diff --git a/runtime/indent/xml.vim b/runtime/indent/xml.vim
index 29069bab84..ad22de1d50 100644
--- a/runtime/indent/xml.vim
+++ b/runtime/indent/xml.vim
@@ -1,9 +1,11 @@
" Language: xml
" Repository: https://github.com/chrisbra/vim-xml-ftplugin
-" Last Changed: Jan 28, 2019
+" Last Changed: Feb 04, 2019
" Maintainer: Christian Brabandt <cb@256bit.org>
" Previous Maintainer: Johannes Zellner <johannes@zellner.org>
" Last Change:
+" 20190204 - correctly handle wrap tags
+" https://github.com/chrisbra/vim-xml-ftplugin/issues/5
" 20190128 - Make sure to find previous tag
" https://github.com/chrisbra/vim-xml-ftplugin/issues/4
" 20181116 - Fix indentation when tags start with a colon or an underscore
@@ -74,13 +76,20 @@ fun! <SID>XmlIndentSynCheck(lnum)
endfun
" [-- return the sum of indents of a:lnum --]
-fun! <SID>XmlIndentSum(lnum, style, add)
- let line = getline(a:lnum)
- if a:style == match(line, '^\s*</')
+fun! <SID>XmlIndentSum(line, style, add)
+ if <SID>IsXMLContinuation(a:line) && a:style == 0
+ " no complete tag, add one additional indent level
+ " but only for the current line
+ return a:add + shiftwidth()
+ elseif <SID>HasNoTagEnd(a:line)
+ " no complete tag, return initial indent
+ return a:add
+ endif
+ if a:style == match(a:line, '^\s*</')
return (shiftwidth() *
- \ (<SID>XmlIndentWithPattern(line, b:xml_indent_open)
- \ - <SID>XmlIndentWithPattern(line, b:xml_indent_close)
- \ - <SID>XmlIndentWithPattern(line, '.\{-}/>'))) + a:add
+ \ (<SID>XmlIndentWithPattern(a:line, b:xml_indent_open)
+ \ - <SID>XmlIndentWithPattern(a:line, b:xml_indent_close)
+ \ - <SID>XmlIndentWithPattern(a:line, '.\{-}/>'))) + a:add
else
return a:add
endif
@@ -89,19 +98,24 @@ endfun
" Main indent function
fun! XmlIndentGet(lnum, use_syntax_check)
" Find a non-empty line above the current line.
- let plnum = prevnonblank(a:lnum - 1)
- " Hit the start of the file, use zero indent.
- if plnum == 0
+ if prevnonblank(a:lnum - 1) == 0
+ " Hit the start of the file, use zero indent.
return 0
endif
" Find previous line with a tag (regardless whether open or closed,
" but always start restrict the match to a line before the current one
+ " Note: xml declaration: <?xml version="1.0"?>
+ " won't be found, as it is not a legal tag name
let ptag_pattern = '\%(.\{-}<[/:A-Z_a-z]\)'. '\%(\&\%<'. line('.').'l\)'
- let ptag = search(ptag_pattern, 'bnw')
+ let ptag = search(ptag_pattern, 'bnW')
+ " no previous tag
+ if ptag == 0
+ return 0
+ endif
let syn_name = ''
if a:use_syntax_check
- let check_lnum = <SID>XmlIndentSynCheck(plnum)
+ let check_lnum = <SID>XmlIndentSynCheck(ptag)
let check_alnum = <SID>XmlIndentSynCheck(a:lnum)
if check_lnum == 0 || check_alnum == 0
return indent(a:lnum)
@@ -113,18 +127,31 @@ fun! XmlIndentGet(lnum, use_syntax_check)
return <SID>XmlIndentComment(a:lnum)
endif
+ let pline = getline(ptag)
+ let pind = indent(ptag)
" Get indent from previous tag line
- let ind = <SID>XmlIndentSum(ptag, -1, indent(ptag))
+ let ind = <SID>XmlIndentSum(pline, -1, pind)
+ let t_ind = ind
" Determine indent from current line
- let ind = <SID>XmlIndentSum(a:lnum, 0, ind)
+ let ind = <SID>XmlIndentSum(getline(a:lnum), 0, ind)
return ind
endfun
+func! <SID>IsXMLContinuation(line)
+ " Checks, whether or not the line matches a start-of-tag
+ return a:line !~ '^\s*<'
+endfunc
+
+func! <SID>HasNoTagEnd(line)
+ " Checks whether or not the line matches '>' (so finishes a tag)
+ return a:line !~ '>\s*$'
+endfunc
+
" return indent for a commented line,
" the middle part might be indented on additional level
func! <SID>XmlIndentComment(lnum)
- let ptagopen = search(b:xml_indent_open, 'bnw')
- let ptagclose = search(b:xml_indent_close, 'bnw')
+ let ptagopen = search(b:xml_indent_open, 'bnW')
+ let ptagclose = search(b:xml_indent_close, 'bnW')
if getline(a:lnum) =~ '<!--'
" if previous tag was a closing tag, do not add
" one additional level of indent
@@ -136,10 +163,10 @@ func! <SID>XmlIndentComment(lnum)
endif
elseif getline(a:lnum) =~ '-->'
" end of comment, same as start of comment
- return indent(search('<!--', 'bnw'))
+ return indent(search('<!--', 'bnW'))
else
" middle part of comment, add one additional level
- return indent(search('<!--', 'bnw')) + shiftwidth()
+ return indent(search('<!--', 'bnW')) + shiftwidth()
endif
endfunc
diff --git a/runtime/syntax/8th.vim b/runtime/syntax/8th.vim
new file mode 100644
index 0000000000..ddc1084c9f
--- /dev/null
+++ b/runtime/syntax/8th.vim
@@ -0,0 +1,335 @@
+" Vim syntax file
+" Language: 8th
+" Version: 19.01d
+" Maintainer: Ron Aaron <ron@aaron-tech.com>
+" URL: https://8th-dev.com/
+" Filetypes: *.8th
+" NOTE: You should also have the ftplugin/8th.vim file to set 'isk'
+
+if version < 600
+ syntax clear
+ finish
+elseif exists("b:current_syntax")
+ finish
+endif
+
+let s:cpo_save = &cpo
+set cpo&vim
+syn clear
+" Synchronization method
+syn sync ccomment
+syn sync maxlines=100
+syn case match
+syn match eighthColonName "\S\+" contained
+syn match eighthColonDef ":\s\+\S\+" contains=eighthColonName
+
+" new words
+syn match eighthClasses "\<\S\+:" contained
+syn match eighthClassWord "\<\S\+:.\+" contains=eighthClasses
+
+syn keyword eighthEndOfColonDef ; i;
+syn keyword eighthDefine var var,
+
+" Built in words
+com! -nargs=+ Builtin syn keyword eighthBuiltin <args>
+"Builtin ^ < <# <#> = > - -- ,# ; ;; ! ??? / . .# ' () @ * */ \
+
+Builtin ! G:! #! G:#! ## G:## #> G:#> #if G:#if ' G:' ( G:( (* G:(* (:) G:(:) (code) G:(code) (getc) G:(getc)
+Builtin (gets) G:(gets) (interp) G:(interp) (needs) G:(needs) (putc) G:(putc) (puts) G:(puts) (putslim) G:(putslim)
+Builtin (say) G:(say) (stat) G:(stat) ) G:) +listener G:+listener +ref G:+ref ,# G:,# -- G:-- -----BEGIN G:-----BEGIN
+Builtin -Inf G:-Inf -Inf? G:-Inf? -listener G:-listener -ref G:-ref -rot G:-rot . G:. .# G:.# .needs G:.needs
+Builtin .r G:.r .s G:.s .stats G:.stats .ver G:.ver .with G:.with 0; G:0; 2dip G:2dip 2drop G:2drop
+Builtin 2dup G:2dup 2over G:2over 2swap G:2swap 3drop G:3drop 4drop G:4drop 8thdt? G:8thdt? 8thver? G:8thver?
+Builtin : G:: ; G:; ;; G:;; ;;; G:;;; ;then G:;then ;with G:;with <# G:<# <#> G:<#> >clip G:>clip >json G:>json
+Builtin >kind G:>kind >n G:>n >r G:>r >s G:>s ?: G:?: ??? G:??? @ G:@ Inf G:Inf Inf? G:Inf? NaN G:NaN
+Builtin NaN? G:NaN? SED-CHECK G:SED-CHECK SED: G:SED: SED: G:SED: \ G:\ ` G:` `` G:`` actor: G:actor:
+Builtin again G:again ahead G:ahead and G:and appname G:appname apropos G:apropos argc G:argc args G:args
+Builtin array? G:array? assert G:assert base G:base bi G:bi bits G:bits break G:break break? G:break?
+Builtin build? G:build? buildver? G:buildver? bye G:bye c# G:c# c/does G:c/does case G:case caseof G:caseof
+Builtin chdir G:chdir clip> G:clip> clone G:clone clone-shallow G:clone-shallow cold G:cold compat-level G:compat-level
+Builtin compile G:compile compile? G:compile? conflict G:conflict const G:const container? G:container?
+Builtin cr G:cr curlang G:curlang curry G:curry curry: G:curry: decimal G:decimal defer: G:defer: deg>rad G:deg>rad
+Builtin depth G:depth die G:die dip G:dip drop G:drop dstack G:dstack dump G:dump dup G:dup dup? G:dup?
+Builtin else G:else enum: G:enum: eval G:eval eval! G:eval! eval0 G:eval0 execnull G:execnull expect G:expect
+Builtin extra! G:extra! extra@ G:extra@ false G:false fnv G:fnv fourth G:fourth free G:free func: G:func:
+Builtin getc G:getc getcwd G:getcwd getenv G:getenv gets G:gets handler G:handler header G:header help G:help
+Builtin hex G:hex i: G:i: i; G:i; if G:if if; G:if; isa? G:isa? items-used G:items-used jcall G:jcall
+Builtin jclass G:jclass jmethod G:jmethod json-nesting G:json-nesting json-pretty G:json-pretty json-throw G:json-throw
+Builtin json> G:json> k32 G:k32 keep G:keep l: G:l: last G:last lib G:lib libbin G:libbin libc G:libc
+Builtin listener@ G:listener@ literal G:literal locals: G:locals: lock G:lock lock-to G:lock-to locked? G:locked?
+Builtin log G:log log-async G:log-async log-task G:log-task log-time G:log-time log-time-local G:log-time-local
+Builtin long-days G:long-days long-months G:long-months loop G:loop loop- G:loop- map? G:map? mark G:mark
+Builtin mark? G:mark? memfree G:memfree mobile? G:mobile? n# G:n# name>os G:name>os name>sem G:name>sem
+Builtin ndrop G:ndrop needs G:needs new G:new next-arg G:next-arg nip G:nip noop G:noop not G:not ns G:ns
+Builtin ns: G:ns: ns>ls G:ns>ls ns>s G:ns>s ns? G:ns? null G:null null; G:null; null? G:null? number? G:number?
+Builtin off G:off on G:on onexit G:onexit only G:only op! G:op! or G:or os G:os os-names G:os-names
+Builtin os>long-name G:os>long-name os>name G:os>name over G:over p: G:p: pack G:pack parse G:parse
+Builtin parsech G:parsech parseln G:parseln parsews G:parsews pick G:pick poke G:poke pool-clear G:pool-clear
+Builtin prior G:prior private G:private process-args G:process-args prompt G:prompt public G:public
+Builtin putc G:putc puts G:puts putslim G:putslim quote G:quote r! G:r! r> G:r> r@ G:r@ rad>deg G:rad>deg
+Builtin rand G:rand rand-pcg G:rand-pcg rand-pcg-seed G:rand-pcg-seed randbuf G:randbuf randbuf-pcg G:randbuf-pcg
+Builtin rdrop G:rdrop recurse G:recurse recurse-stack G:recurse-stack ref@ G:ref@ reg! G:reg! reg@ G:reg@
+Builtin regbin@ G:regbin@ remaining-args G:remaining-args repeat G:repeat reset G:reset roll G:roll
+Builtin rop! G:rop! rot G:rot rpick G:rpick rroll G:rroll rstack G:rstack rswap G:rswap rusage G:rusage
+Builtin s>ns G:s>ns same? G:same? scriptdir G:scriptdir scriptfile G:scriptfile sem G:sem sem-post G:sem-post
+Builtin sem-rm G:sem-rm sem-wait G:sem-wait sem-wait? G:sem-wait? sem>name G:sem>name semi-throw G:semi-throw
+Builtin set-wipe G:set-wipe setenv G:setenv settings! G:settings! settings![] G:settings![] settings@ G:settings@
+Builtin settings@? G:settings@? settings@[] G:settings@[] sh G:sh sh$ G:sh$ short-days G:short-days
+Builtin short-months G:short-months sleep G:sleep space G:space stack-check G:stack-check stack-size G:stack-size
+Builtin step G:step string? G:string? struct: G:struct: swap G:swap syslang G:syslang sysregion G:sysregion
+Builtin tab-hook G:tab-hook tell-conflict G:tell-conflict tempdir G:tempdir tempfilename G:tempfilename
+Builtin then G:then third G:third throw G:throw thrownull G:thrownull times G:times tlog G:tlog tri G:tri
+Builtin true G:true tuck G:tuck type-check G:type-check typeassert G:typeassert unlock G:unlock unpack G:unpack
+Builtin until G:until until! G:until! var G:var var, G:var, while G:while while! G:while! with: G:with:
+Builtin words G:words words-like G:words-like words/ G:words/ xchg G:xchg xor G:xor >auth HTTP:>auth
+Builtin sh I:sh tpush I:tpush trace-word I:trace-word call JSONRPC:call auth-string OAuth:auth-string
+Builtin gen-nonce OAuth:gen-nonce params OAuth:params call SOAP:call ! a:! + a:+ - a:- 2each a:2each
+Builtin 2map a:2map 2map+ a:2map+ 2map= a:2map= = a:= >map a:>map @ a:@ @@ a:@@ bsearch a:bsearch clear a:clear
+Builtin close a:close diff a:diff dot a:dot each a:each each-slice a:each-slice exists? a:exists? filter a:filter
+Builtin generate a:generate group a:group indexof a:indexof insert a:insert intersect a:intersect join a:join
+Builtin len a:len map a:map map+ a:map+ map= a:map= mean a:mean mean&variance a:mean&variance new a:new
+Builtin op a:op op! a:op! op= a:op= open a:open pop a:pop push a:push qsort a:qsort randeach a:randeach
+Builtin reduce a:reduce reduce+ a:reduce+ rev a:rev shift a:shift shuffle a:shuffle slice a:slice slice+ a:slice+
+Builtin slide a:slide sort a:sort union a:union when a:when when! a:when! x a:x x-each a:x-each xchg a:xchg
+Builtin y a:y zip a:zip 8thdir app:8thdir asset app:asset atrun app:atrun atrun app:atrun atrun app:atrun
+Builtin basedir app:basedir current app:current datadir app:datadir exename app:exename isgui app:isgui
+Builtin main app:main oncrash app:oncrash orientation app:orientation pid app:pid restart app:restart
+Builtin resumed app:resumed shared? app:shared? standalone app:standalone subdir app:subdir suspended app:suspended
+Builtin sysquit app:sysquit (here) asm:(here) >n asm:>n avail asm:avail c, asm:c, here! asm:here! n> asm:n>
+Builtin used asm:used w, asm:w, ! b:! + b:+ / b:/ = b:= >base64 b:>base64 >hex b:>hex >mpack b:>mpack
+Builtin @ b:@ append b:append base64> b:base64> bit! b:bit! bit@ b:bit@ clear b:clear compress b:compress
+Builtin conv b:conv each b:each each-slice b:each-slice expand b:expand fill b:fill getb b:getb hex> b:hex>
+Builtin len b:len mem> b:mem> move b:move mpack-date b:mpack-date mpack-ignore b:mpack-ignore mpack> b:mpack>
+Builtin new b:new op b:op rev b:rev search b:search shmem b:shmem slice b:slice splice b:splice ungetb b:ungetb
+Builtin writable b:writable xor b:xor +block bc:+block .blocks bc:.blocks add-block bc:add-block block-hash bc:block-hash
+Builtin block@ bc:block@ first-block bc:first-block hash bc:hash last-block bc:last-block load bc:load
+Builtin new bc:new save bc:save set-sql bc:set-sql validate bc:validate validate-block bc:validate-block
+Builtin add bloom:add filter bloom:filter in? bloom:in? accept bt:accept ch! bt:ch! ch@ bt:ch@ connect bt:connect
+Builtin disconnect bt:disconnect err? bt:err? leconnect bt:leconnect lescan bt:lescan listen bt:listen
+Builtin on? bt:on? read bt:read scan bt:scan service? bt:service? services? bt:services? write bt:write
+Builtin * c:* * c:* + c:+ + c:+ = c:= = c:= >ri c:>ri >ri c:>ri abs c:abs abs c:abs arg c:arg arg c:arg
+Builtin conj c:conj conj c:conj im c:im n> c:n> new c:new new c:new re c:re >aes128gcm cr:>aes128gcm
+Builtin >aes256gcm cr:>aes256gcm >cp cr:>cp >cpe cr:>cpe >decrypt cr:>decrypt >edbox cr:>edbox >encrypt cr:>encrypt
+Builtin >nbuf cr:>nbuf >rsabox cr:>rsabox >uuid cr:>uuid CBC cr:CBC CFB cr:CFB CTR cr:CTR ECB cr:ECB
+Builtin GCM cr:GCM OFB cr:OFB aad? cr:aad? aes128box-sig cr:aes128box-sig aes128gcm> cr:aes128gcm>
+Builtin aes256box-sig cr:aes256box-sig aes256gcm> cr:aes256gcm> aesgcm cr:aesgcm blakehash cr:blakehash
+Builtin chacha20box-sig cr:chacha20box-sig chachapoly cr:chachapoly cipher! cr:cipher! cipher@ cr:cipher@
+Builtin cp> cr:cp> cpe> cr:cpe> decrypt cr:decrypt decrypt+ cr:decrypt+ decrypt> cr:decrypt> dh-genkey cr:dh-genkey
+Builtin dh-secret cr:dh-secret dh-sign cr:dh-sign dh-verify cr:dh-verify ebox-sig cr:ebox-sig ecc-genkey cr:ecc-genkey
+Builtin ecc-secret cr:ecc-secret ecc-sign cr:ecc-sign ecc-verify cr:ecc-verify edbox-sig cr:edbox-sig
+Builtin edbox> cr:edbox> encrypt cr:encrypt encrypt+ cr:encrypt+ encrypt> cr:encrypt> ensurekey cr:ensurekey
+Builtin err? cr:err? gcm-tag-size cr:gcm-tag-size genkey cr:genkey hash cr:hash hash! cr:hash! hash+ cr:hash+
+Builtin hash>b cr:hash>b hash>s cr:hash>s hash@ cr:hash@ hmac cr:hmac hotp cr:hotp iv? cr:iv? mode cr:mode
+Builtin mode@ cr:mode@ randkey cr:randkey restore cr:restore root-certs cr:root-certs rsa_decrypt cr:rsa_decrypt
+Builtin rsa_encrypt cr:rsa_encrypt rsa_sign cr:rsa_sign rsa_verify cr:rsa_verify rsabox-sig cr:rsabox-sig
+Builtin rsabox> cr:rsabox> rsagenkey cr:rsagenkey save cr:save sbox-sig cr:sbox-sig sha1-hmac cr:sha1-hmac
+Builtin shard cr:shard tag? cr:tag? totp cr:totp totp-epoch cr:totp-epoch totp-time-step cr:totp-time-step
+Builtin unshard cr:unshard uuid cr:uuid uuid> cr:uuid> validate-pgp-sig cr:validate-pgp-sig (.hebrew) d:(.hebrew)
+Builtin (.islamic) d:(.islamic) + d:+ +day d:+day +hour d:+hour +min d:+min +msec d:+msec - d:- .hebrew d:.hebrew
+Builtin .islamic d:.islamic .time d:.time / d:/ = d:= >fixed d:>fixed >hebepoch d:>hebepoch >msec d:>msec
+Builtin >unix d:>unix >ymd d:>ymd Adar d:Adar Adar2 d:Adar2 Adar2 d:Adar2 Av d:Av Elul d:Elul Fri d:Fri
+Builtin Heshvan d:Heshvan Iyar d:Iyar Kislev d:Kislev Mon d:Mon Nissan d:Nissan Sat d:Sat Shevat d:Shevat
+Builtin Sivan d:Sivan Sun d:Sun Tammuz d:Tammuz Tevet d:Tevet Thu d:Thu Tishrei d:Tishrei Tue d:Tue
+Builtin Wed d:Wed adjust-dst d:adjust-dst between d:between d. d:d. dawn d:dawn days-in-hebrew-year d:days-in-hebrew-year
+Builtin displaying-hebrew d:displaying-hebrew do-dawn d:do-dawn do-dusk d:do-dusk do-rise d:do-rise
+Builtin doy d:doy dst? d:dst? dstquery d:dstquery dstzones? d:dstzones? dusk d:dusk elapsed-timer d:elapsed-timer
+Builtin elapsed-timer-seconds d:elapsed-timer-seconds first-dow d:first-dow fixed> d:fixed> fixed>dow d:fixed>dow
+Builtin fixed>hebrew d:fixed>hebrew fixed>islamic d:fixed>islamic format d:format hanukkah d:hanukkah
+Builtin hebrew-epoch d:hebrew-epoch hebrew>fixed d:hebrew>fixed hebrewtoday d:hebrewtoday hmonth-name d:hmonth-name
+Builtin islamic.epoch d:islamic.epoch islamic>fixed d:islamic>fixed islamictoday d:islamictoday join d:join
+Builtin last-day-of-hebrew-month d:last-day-of-hebrew-month last-dow d:last-dow last-month d:last-month
+Builtin last-week d:last-week last-year d:last-year latitude d:latitude longitude d:longitude longitude d:longitude
+Builtin msec d:msec msec> d:msec> new d:new next-dow d:next-dow next-month d:next-month next-week d:next-week
+Builtin next-year d:next-year number>hebrew d:number>hebrew omer d:omer parse d:parse pesach d:pesach
+Builtin prev-dow d:prev-dow purim d:purim rosh-chodesh? d:rosh-chodesh? rosh-hashanah d:rosh-hashanah
+Builtin shavuot d:shavuot start-timer d:start-timer sunrise d:sunrise taanit-esther d:taanit-esther
+Builtin ticks d:ticks ticks/sec d:ticks/sec timer d:timer tisha-beav d:tisha-beav tzadjust d:tzadjust
+Builtin unix> d:unix> updatetz d:updatetz year@ d:year@ ymd d:ymd ymd> d:ymd> yom-haatsmaut d:yom-haatsmaut
+Builtin yom-kippur d:yom-kippur add-func db:add-func bind db:bind close db:close col db:col col[] db:col[]
+Builtin col{} db:col{} err? db:err? errmsg db:errmsg exec db:exec exec-cb db:exec-cb key db:key mysql? db:mysql?
+Builtin odbc? db:odbc? open db:open open? db:open? prepare db:prepare query db:query query-all db:query-all
+Builtin rekey db:rekey sqlerrmsg db:sqlerrmsg bp dbg:bp except-task@ dbg:except-task@ go dbg:go line-info dbg:line-info
+Builtin prompt dbg:prompt stop dbg:stop trace dbg:trace trace-enter dbg:trace-enter trace-leave dbg:trace-leave
+Builtin abspath f:abspath append f:append associate f:associate atime f:atime canwrite? f:canwrite?
+Builtin chmod f:chmod close f:close copy f:copy copydir f:copydir create f:create ctime f:ctime dir? f:dir?
+Builtin dname f:dname eachbuf f:eachbuf eachline f:eachline enssep f:enssep eof? f:eof? err? f:err?
+Builtin exists? f:exists? flush f:flush fname f:fname getb f:getb getc f:getc getline f:getline getmod f:getmod
+Builtin glob f:glob glob-nocase f:glob-nocase include f:include launch f:launch link f:link link> f:link>
+Builtin link? f:link? mkdir f:mkdir mmap f:mmap mmap-range f:mmap-range mmap-range? f:mmap-range? mtime f:mtime
+Builtin mv f:mv open f:open open-ro f:open-ro popen f:popen print f:print read f:read relpath f:relpath
+Builtin rglob f:rglob rm f:rm rmdir f:rmdir seek f:seek sep f:sep show f:show size f:size slurp f:slurp
+Builtin stderr f:stderr stdin f:stdin stdout f:stdout tell f:tell times f:times trash f:trash ungetb f:ungetb
+Builtin ungetc f:ungetc unzip f:unzip unzip-entry f:unzip-entry watch f:watch write f:write writen f:writen
+Builtin zip+ f:zip+ zip@ f:zip@ zipentry f:zipentry zipnew f:zipnew zipopen f:zipopen zipsave f:zipsave
+Builtin bold font:bold face? font:face? glyph-path font:glyph-path glyph-pos font:glyph-pos info font:info
+Builtin italic font:italic ls font:ls measure font:measure new font:new pixels font:pixels pixels? font:pixels?
+Builtin points font:points points? font:points? styles font:styles styles? font:styles? underline font:underline
+Builtin +child g:+child +kind g:+kind +path g:+path -child g:-child /path g:/path >img g:>img >progress g:>progress
+Builtin add-items g:add-items adjustwidth g:adjustwidth allow-orient g:allow-orient arc g:arc arc2 g:arc2
+Builtin autohide g:autohide back g:back bezier g:bezier bg g:bg bg? g:bg? bounds g:bounds bounds? g:bounds?
+Builtin box-label g:box-label btn-font g:btn-font bubble g:bubble button-size g:button-size buttons-visible g:buttons-visible
+Builtin c-text g:c-text callout g:callout center g:center child g:child clear g:clear clearpath g:clearpath
+Builtin clr>n g:clr>n coleven g:coleven colordlg g:colordlg colwidth g:colwidth connectededges g:connectededges
+Builtin contrasting g:contrasting cp g:cp curmouse? g:curmouse? default-font g:default-font deselect-row g:deselect-row
+Builtin dismiss g:dismiss do g:do draw-fitted-text g:draw-fitted-text draw-text g:draw-text draw-text-at g:draw-text-at
+Builtin each g:each edit-on-double-click g:edit-on-double-click editable g:editable editdlg g:editdlg
+Builtin empty-text g:empty-text enable g:enable enabled? g:enabled? fade g:fade fb-files g:fb-files
+Builtin fcolor g:fcolor fg g:fg fg? g:fg? file-filter g:file-filter file-name g:file-name filedlg g:filedlg
+Builtin fill g:fill fillall g:fillall fit-text g:fit-text flex! g:flex! focus g:focus fontdlg g:fontdlg
+Builtin forward g:forward fullscreen g:fullscreen get-lasso-items g:get-lasso-items get-tab g:get-tab
+Builtin getclr g:getclr getfont g:getfont getimage g:getimage getpath g:getpath getroot g:getroot gradient g:gradient
+Builtin gui? g:gui? handle g:handle headerheight g:headerheight hide g:hide image g:image image-at g:image-at
+Builtin invalidate g:invalidate ix? g:ix? justify g:justify keyinfo g:keyinfo l-text g:l-text laf g:laf
+Builtin laf! g:laf! laf? g:laf? len g:len line-width g:line-width lineto g:lineto list+ g:list+ list- g:list-
+Builtin loadcontent g:loadcontent localize g:localize m! g:m! m@ g:m@ menu-font g:menu-font menu-update g:menu-update
+Builtin menuenabled g:menuenabled mouse? g:mouse? mousepos? g:mousepos? moveto g:moveto msgdlg g:msgdlg
+Builtin multi g:multi name g:name named-skin g:named-skin new g:new new-laf g:new-laf next g:next obj g:obj
+Builtin on g:on on? g:on? ontop g:ontop oshandle g:oshandle outlinethickness g:outlinethickness panel-size g:panel-size
+Builtin panel-size? g:panel-size? parent g:parent path g:path path>s g:path>s pie g:pie pix! g:pix!
+Builtin pop g:pop popmenu g:popmenu pos? g:pos? prev g:prev propval! g:propval! propval@ g:propval@
+Builtin push g:push qbezier g:qbezier quit g:quit r-text g:r-text readonly g:readonly rect g:rect refresh g:refresh
+Builtin restore g:restore root g:root root-item-visible g:root-item-visible rotate g:rotate rowheight g:rowheight
+Builtin rrect g:rrect s>path g:s>path save g:save say g:say scale g:scale scolor g:scolor scrollthickness g:scrollthickness
+Builtin sectionenable g:sectionenable select! g:select! select@ g:select@ selected-rows g:selected-rows
+Builtin set-lasso g:set-lasso set-long-press g:set-long-press set-popup-font g:set-popup-font set-range g:set-range
+Builtin set-swipe g:set-swipe set-value g:set-value setcursor g:setcursor setfont g:setfont setheader g:setheader
+Builtin sethtml g:sethtml setimage g:setimage setname g:setname setroot g:setroot settab g:settab show g:show
+Builtin show-line-numbers g:show-line-numbers show-pct g:show-pct showmenu g:showmenu showtooltip g:showtooltip
+Builtin size g:size size? g:size? skin g:skin skin-class g:skin-class stackix g:stackix state g:state
+Builtin state? g:state? stepsize g:stepsize stroke g:stroke stroke-fill g:stroke-fill style g:style
+Builtin tabname g:tabname text g:text text-box-style g:text-box-style text? g:text? textcolor g:textcolor
+Builtin textsize g:textsize timer! g:timer! timer@ g:timer@ toback g:toback tofront g:tofront toggle-row g:toggle-row
+Builtin tooltip g:tooltip top g:top transition g:transition translate g:translate tree-open g:tree-open
+Builtin triangle g:triangle update g:update updateitems g:updateitems url g:url user g:user user! g:user!
+Builtin vertical g:vertical view g:view visible? g:visible? vpos! g:vpos! vpos@ g:vpos@ waitcursor g:waitcursor
+Builtin winding g:winding xy g:xy xy? g:xy? +edge gr:+edge +edge+w gr:+edge+w +node gr:+node connect gr:connect
+Builtin edges gr:edges m! gr:m! m@ gr:m@ neighbors gr:neighbors new gr:new node-edges gr:node-edges
+Builtin nodes gr:nodes traverse gr:traverse + h:+ clear h:clear len h:len new h:new peek h:peek pop h:pop
+Builtin push h:push unique h:unique arm? hw:arm? camera hw:camera camera-fmt hw:camera-fmt camera-img hw:camera-img
+Builtin camera? hw:camera? cpu? hw:cpu? device? hw:device? displays? hw:displays? displaysize? hw:displaysize?
+Builtin err? hw:err? gpio hw:gpio gpio! hw:gpio! gpio-mmap hw:gpio-mmap gpio@ hw:gpio@ i2c hw:i2c i2c! hw:i2c!
+Builtin i2c!reg hw:i2c!reg i2c@ hw:i2c@ i2c@reg hw:i2c@reg isround? hw:isround? iswatch? hw:iswatch?
+Builtin mac? hw:mac? mem? hw:mem? poll hw:poll sensor hw:sensor start hw:start stop hw:stop fetch-full imap:fetch-full
+Builtin fetch-uid-mail imap:fetch-uid-mail login imap:login new imap:new select-inbox imap:select-inbox
+Builtin >file img:>file copy img:copy crop img:crop data img:data desat img:desat fill img:fill filter img:filter
+Builtin flip img:flip from-svg img:from-svg new img:new pix! img:pix! pix@ img:pix@ qr-gen img:qr-gen
+Builtin qr-parse img:qr-parse rotate img:rotate scale img:scale scroll img:scroll size img:size countries iso:countries
+Builtin find loc:find sort loc:sort ! m:! !? m:!? + m:+ +? m:+? - m:- @ m:@ @? m:@? @@ m:@@ clear m:clear
+Builtin data m:data each m:each exists? m:exists? iter m:iter iter-all m:iter-all keys m:keys len m:len
+Builtin map m:map new m:new op! m:op! open m:open vals m:vals xchg m:xchg ! mat:! * mat:* + mat:+ = mat:=
+Builtin @ mat:@ col mat:col data mat:data det mat:det dim? mat:dim? get-n mat:get-n ident mat:ident
+Builtin m. mat:m. minor mat:minor n* mat:n* new mat:new row mat:row same-size? mat:same-size? trans mat:trans
+Builtin ! n:! * n:* */ n:*/ + n:+ +! n:+! - n:- / n:/ /mod n:/mod 1+ n:1+ 1- n:1- < n:< = n:= > n:>
+Builtin BIGE n:BIGE BIGPI n:BIGPI E n:E PI n:PI ^ n:^ abs n:abs acos n:acos acos n:acos asin n:asin
+Builtin asin n:asin atan n:atan atan n:atan atan2 n:atan2 band n:band between n:between bfloat n:bfloat
+Builtin bic n:bic bint n:bint binv n:binv bnot n:bnot bor n:bor bxor n:bxor ceil n:ceil clamp n:clamp
+Builtin cmp n:cmp comb n:comb cos n:cos cosd n:cosd exp n:exp expmod n:expmod float n:float floor n:floor
+Builtin fmod n:fmod frac n:frac gcd n:gcd int n:int invmod n:invmod kind? n:kind? lcm n:lcm ln n:ln
+Builtin max n:max median n:median min n:min mod n:mod neg n:neg odd? n:odd? perm n:perm prime? n:prime?
+Builtin quantize n:quantize quantize! n:quantize! r+ n:r+ range n:range rot32l n:rot32l rot32r n:rot32r
+Builtin round n:round round2 n:round2 running-variance n:running-variance running-variance-finalize n:running-variance-finalize
+Builtin sgn n:sgn shl n:shl shr n:shr sin n:sin sind n:sind sqr n:sqr sqrt n:sqrt tan n:tan tand n:tand
+Builtin trunc n:trunc ~= n:~= ! net:! >url net:>url @ net:@ DGRAM net:DGRAM INET4 net:INET4 INET6 net:INET6
+Builtin PROTO_TCP net:PROTO_TCP PROTO_UDP net:PROTO_UDP STREAM net:STREAM accept net:accept addrinfo>o net:addrinfo>o
+Builtin again? net:again? alloc-and-read net:alloc-and-read alloc-buf net:alloc-buf bind net:bind browse net:browse
+Builtin close net:close connect net:connect err>s net:err>s err? net:err? get net:get getaddrinfo net:getaddrinfo
+Builtin getpeername net:getpeername head net:head ifaces? net:ifaces? listen net:listen net-socket net:net-socket
+Builtin opts net:opts port-is-ssl? net:port-is-ssl? post net:post proxy! net:proxy! read net:read recvfrom net:recvfrom
+Builtin s>url net:s>url sendto net:sendto server net:server setsockopt net:setsockopt socket net:socket
+Builtin tlshello net:tlshello url> net:url> user-agent net:user-agent wait net:wait write net:write
+Builtin MAX ns:MAX cast ptr:cast len ptr:len pack ptr:pack unpack ptr:unpack unpack_orig ptr:unpack_orig
+Builtin + q:+ clear q:clear len q:len new q:new notify q:notify overwrite q:overwrite peek q:peek pick q:pick
+Builtin pop q:pop push q:push shift q:shift size q:size slide q:slide throwing q:throwing wait q:wait
+Builtin ++match r:++match +/ r:+/ +match r:+match / r:/ @ r:@ err? r:err? len r:len match r:match new r:new
+Builtin rx r:rx str r:str ! s:! * s:* + s:+ - s:- / s:/ /scripts s:/scripts <+ s:<+ = s:= =ic s:=ic
+Builtin >base64 s:>base64 >ucs2 s:>ucs2 @ s:@ append s:append base64> s:base64> clear s:clear cmp s:cmp
+Builtin cmpi s:cmpi compress s:compress days! s:days! each s:each eachline s:eachline expand s:expand
+Builtin fill s:fill fmt s:fmt gershayim s:gershayim globmatch s:globmatch hexupr s:hexupr insert s:insert
+Builtin intl s:intl intl! s:intl! lang s:lang lc s:lc len s:len lsub s:lsub ltrim s:ltrim map s:map
+Builtin months! s:months! new s:new replace s:replace replace! s:replace! rev s:rev rsearch s:rsearch
+Builtin rsub s:rsub rtrim s:rtrim script? s:script? search s:search size s:size slice s:slice strfmap s:strfmap
+Builtin strfmt s:strfmt trim s:trim tsub s:tsub uc s:uc ucs2> s:ucs2> utf8? s:utf8? zt s:zt close sio:close
+Builtin enum sio:enum open sio:open opts! sio:opts! opts@ sio:opts@ read sio:read write sio:write new smtp:new
+Builtin send smtp:send apply-filter snd:apply-filter devices? snd:devices? end-record snd:end-record
+Builtin filter snd:filter formats? snd:formats? freq snd:freq gain snd:gain gain? snd:gain? len snd:len
+Builtin loop snd:loop mix snd:mix new snd:new pause snd:pause play snd:play played snd:played rate snd:rate
+Builtin record snd:record seek snd:seek stop snd:stop stopall snd:stopall unmix snd:unmix volume snd:volume
+Builtin volume? snd:volume? + st:+ . st:. clear st:clear len st:len ndrop st:ndrop new st:new op! st:op!
+Builtin peek st:peek pick st:pick pop st:pop push st:push roll st:roll shift st:shift size st:size
+Builtin slide st:slide swap st:swap throwing st:throwing >buf struct:>buf arr> struct:arr> buf struct:buf
+Builtin buf> struct:buf> byte struct:byte double struct:double field! struct:field! field@ struct:field@
+Builtin float struct:float ignore struct:ignore int struct:int long struct:long struct; struct:struct;
+Builtin word struct:word ! t:! @ t:@ assign t:assign curtask t:curtask def-queue t:def-queue def-stack t:def-stack
+Builtin done? t:done? err! t:err! err? t:err? getq t:getq guitask t:guitask handler t:handler kill t:kill
+Builtin list t:list main t:main name! t:name! name@ t:name@ notify t:notify pop t:pop priority t:priority
+Builtin push t:push push< t:push< q-notify t:q-notify q-wait t:q-wait qlen t:qlen result t:result task t:task
+Builtin task-n t:task-n task-stop t:task-stop wait t:wait ! w:! @ w:@ alias: w:alias: cb w:cb deprecate w:deprecate
+Builtin exec w:exec exec? w:exec? ffifail w:ffifail find w:find forget w:forget is w:is undo w:undo
+Builtin >s xml:>s >txt xml:>txt parse xml:parse parse-html xml:parse-html parse-stream xml:parse-stream
+Builtin getmsg[] zmq:getmsg[] sendmsg[] zmq:sendmsg[]
+" numbers
+syn keyword eighthMath decimal hex base@ base!
+syn match eighthInteger '\<-\=[0-9.]*[0-9.]\+\>'
+" recognize hex and binary numbers, the '$' and '%' notation is for eighth
+syn match eighthInteger '\<\$\x*\x\+\>' " *1* --- dont't mess
+syn match eighthInteger '\<\x*\d\x*\>' " *2* --- this order!
+syn match eighthInteger '\<%[0-1]*[0-1]\+\>'
+syn match eighthInteger "\<'.\>"
+
+" Strings
+syn region eighthString start=+\.\?\"+ skip=+"+ end=+$+
+syn keyword jsonNull null
+syn keyword jsonBool /\(true\|false\)/
+ syn region eighthString start=/\<"/ end=/"\>/
+syn match jsonObjEntry /"\"[^"]\+\"\ze\s*:/
+
+"syn region jsonObject start=/{/ end=/}/ contained contains=jsonObjEntry,jsonArray,jsonObject, jsonBool, eighthString
+"syn region jsonArray start=/\[/ end=/\]/ contained contains=jsonArray,jsonObject, jsonBool, eighthString
+
+" Include files
+" syn match eighthInclude '\<\(libinclude\|include\|needs\)\s\+\S\+'
+syn region eighthComment start="\zs\\" end="$" contains=eighthTodo
+
+" Define the default highlighting.
+if !exists("did_eighth_syntax_inits")
+ let did_eighth_syntax_inits=1
+ " The default methods for highlighting. Can be overriden later.
+ hi def link eighthTodo Todo
+ hi def link eighthOperators Operator
+ hi def link eighthMath Number
+ hi def link eighthInteger Number
+ hi def link eighthStack Special
+ hi def link eighthFStack Special
+ hi def link eighthSP Special
+ hi def link eighthColonDef Define
+ hi def link eighthColonName Operator
+ hi def link eighthEndOfColonDef Define
+ hi def link eighthDefine Define
+ hi def link eighthDebug Debug
+ hi def link eighthCharOps Character
+ hi def link eighthConversion String
+ hi def link eighthForth Statement
+ hi def link eighthVocs Statement
+ hi def link eighthString String
+ hi def link eighthComment Comment
+ hi def link eighthClassDef Define
+ hi def link eighthEndOfClassDef Define
+ hi def link eighthObjectDef Define
+ hi def link eighthEndOfObjectDef Define
+ hi def link eighthInclude Include
+ hi def link eighthBuiltin Define
+ hi def link eighthClasses Define
+ hi def link eighthClassWord Keyword
+
+ hi def link jsonObject Delimiter
+ hi def link jsonObjEntry Label
+ hi def link jsonArray Special
+ hi def link jsonNull Function
+ hi def link jsonBool Boolean
+endif
+
+let b:current_syntax = "8th"
+let &cpo = s:cpo_save
+unlet s:cpo_save
+
+" vim: ts=8:sw=4:nocindent:smartindent:
diff --git a/runtime/syntax/c.vim b/runtime/syntax/c.vim
index 95d3455dde..2a14ae0c46 100644
--- a/runtime/syntax/c.vim
+++ b/runtime/syntax/c.vim
@@ -1,7 +1,7 @@
" Vim syntax file
" Language: C
" Maintainer: Bram Moolenaar <Bram@vim.org>
-" Last Change: 2018 Sep 21
+" Last Change: 2019 Apr 23
" Quit when a (custom) syntax file was already loaded
if exists("b:current_syntax")
@@ -289,6 +289,22 @@ if !exists("c_no_c11")
syn keyword cOperator _Static_assert static_assert
syn keyword cStorageClass _Thread_local thread_local
syn keyword cType char16_t char32_t
+ " C11 atomics (take down the shield wall!)
+ syn keyword cType atomic_bool atomic_char atomic_schar atomic_uchar
+ syn keyword Ctype atomic_short atomic_ushort atomic_int atomic_uint
+ syn keyword cType atomic_long atomic_ulong atomic_llong atomic_ullong
+ syn keyword cType atomic_char16_t atomic_char32_t atomic_wchar_t
+ syn keyword cType atomic_int_least8_t atomic_uint_least8_t
+ syn keyword cType atomic_int_least16_t atomic_uint_least16_t
+ syn keyword cType atomic_int_least32_t atomic_uint_least32_t
+ syn keyword cType atomic_int_least64_t atomic_uint_least64_t
+ syn keyword cType atomic_int_fast8_t atomic_uint_fast8_t
+ syn keyword cType atomic_int_fast16_t atomic_uint_fast16_t
+ syn keyword cType atomic_int_fast32_t atomic_uint_fast32_t
+ syn keyword cType atomic_int_fast64_t atomic_uint_fast64_t
+ syn keyword cType atomic_intptr_t atomic_uintptr_t
+ syn keyword cType atomic_size_t atomic_ptrdiff_t
+ syn keyword cType atomic_intmax_t atomic_uintmax_t
endif
if !exists("c_no_ansi") || exists("c_ansi_constants") || exists("c_gnu")
@@ -342,7 +358,7 @@ if !exists("c_no_ansi") || exists("c_ansi_constants") || exists("c_gnu")
syn keyword cConstant EINPROGRESS EINTR EINVAL EIO EISCONN EISDIR ELOOP EMFILE EMLINK EMSGSIZE
syn keyword cConstant EMULTIHOP ENAMETOOLONG ENETDOWN ENETRESET ENETUNREACH ENFILE ENOBUFS ENODATA
syn keyword cConstant ENODEV ENOENT ENOEXEC ENOLCK ENOLINK ENOMEM ENOMSG ENOPROTOOPT ENOSPC ENOSR
- syn keyword cConstant ENOSTR ENOSYS ENOTCONN ENOTDIR ENOTEMPTY ENOTRECOVERABLE ENOTSOCK ENOTSUP
+ syn keyword cConstant ENOSTR ENOSYS ENOTBLK ENOTCONN ENOTDIR ENOTEMPTY ENOTRECOVERABLE ENOTSOCK ENOTSUP
syn keyword cConstant ENOTTY ENXIO EOPNOTSUPP EOVERFLOW EOWNERDEAD EPERM EPIPE EPROTO
syn keyword cConstant EPROTONOSUPPORT EPROTOTYPE ERANGE EROFS ESPIPE ESRCH ESTALE ETIME ETIMEDOUT
syn keyword cConstant ETXTBSY EWOULDBLOCK EXDEV
diff --git a/runtime/syntax/cobol.vim b/runtime/syntax/cobol.vim
index 2d481bba0b..5d649441a3 100644
--- a/runtime/syntax/cobol.vim
+++ b/runtime/syntax/cobol.vim
@@ -1,10 +1,23 @@
" Vim syntax file
" Language: COBOL
-" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
+" Maintainer: Ankit Jain <ajatkj@yahoo.co.in>
+" (formerly Tim Pope <vimNOSPAM@tpope.info>)
" (formerly Davyd Ondrejko <vondraco@columbus.rr.com>)
" (formerly Sitaram Chamarty <sitaram@diac.com> and
" James Mitchell <james_mitchell@acm.org>)
-" Last Change: 2015 Feb 13
+" Last Change: 2019 Mar 22
+" Ankit Jain 22.03.2019 Changes & fixes:
+" 1. Include inline comments
+" 2. Use comment highlight for bad lines
+" 3. Change certain 'keywords' to 'matches'
+" for additional highlighting
+" 4. Different highlighting for COPY, GO TO &
+" CALL lines
+" 5. Fix for COMP keyword
+" 6. Fix for PROCEDURE DIVISION highlighting
+" 7. Highlight EXIT PROGRAM like STOP RUN
+" 8. Highlight X & A in PIC clause
+" Tag: #C22032019
" quit when a syntax file was already loaded
if exists("b:current_syntax")
@@ -12,7 +25,11 @@ if exists("b:current_syntax")
endif
" MOST important - else most of the keywords wont work!
-setlocal isk=@,48-57,-
+setlocal isk=@,48-57,-,_
+
+if !exists('g:cobol_inline_comment')
+ let g:cobol_inline_comment=0
+endif
syn case ignore
@@ -29,7 +46,10 @@ syn match cobolComment "[/*C].*$" contained
syn match cobolCompiler "$.*$" contained
syn match cobolLine ".*$" contained contains=cobolReserved,@cobolLine
-syn match cobolDivision "[A-Z][A-Z0-9-]*[A-Z0-9]\s\+DIVISION\."he=e-1 contained contains=cobolDivisionName
+"#C22032019: Fix for PROCEDURE DIVISION USING highlighting, removed . from the
+"end of the regex
+"syn match cobolDivision \"[A-Z][A-Z0-9-]*[A-Z0-9]\s\+DIVISION\."he=e-1 contained contains=cobolDivisionName
+syn match cobolDivision "[A-Z][A-Z0-9-]*[A-Z0-9]\s\+DIVISION" contained contains=cobolDivisionName
syn keyword cobolDivisionName contained IDENTIFICATION ENVIRONMENT DATA PROCEDURE
syn match cobolSection "[A-Z][A-Z0-9-]*[A-Z0-9]\s\+SECTION\."he=e-1 contained contains=cobolSectionName
syn keyword cobolSectionName contained CONFIGURATION INPUT-OUTPUT FILE WORKING-STORAGE LOCAL-STORAGE LINKAGE
@@ -38,10 +58,12 @@ syn keyword cobolParagraphName contained PROGRAM-ID SOURCE-COMPUTER OBJECT-COMP
"syn match cobolKeys "^\a\{1,6\}" contains=cobolReserved
+"#C22032019: Remove BY, REPLACING, PROGRAM, TO, IN from 'keyword' group and add
+"to 'match' group or other 'keyword' group
syn keyword cobolReserved contained ACCEPT ACCESS ADD ADDRESS ADVANCING AFTER ALPHABET ALPHABETIC
syn keyword cobolReserved contained ALPHABETIC-LOWER ALPHABETIC-UPPER ALPHANUMERIC ALPHANUMERIC-EDITED ALS
syn keyword cobolReserved contained ALTERNATE AND ANY ARE AREA AREAS ASCENDING ASSIGN AT AUTHOR BEFORE BINARY
-syn keyword cobolReserved contained BLANK BLOCK BOTTOM BY CANCEL CBLL CD CF CH CHARACTER CHARACTERS CLASS
+syn keyword cobolReserved contained BLANK BLOCK BOTTOM CANCEL CBLL CD CF CH CHARACTER CHARACTERS CLASS
syn keyword cobolReserved contained CLOCK-UNITS CLOSE COBOL CODE CODE-SET COLLATING COLUMN COMMA COMMON
syn keyword cobolReserved contained COMMUNICATIONS COMPUTATIONAL COMPUTE CONTENT CONTINUE
syn keyword cobolReserved contained CONTROL CONVERTING CORR CORRESPONDING COUNT CURRENCY DATE DATE-COMPILED
@@ -55,52 +77,79 @@ syn keyword cobolReserved contained END-REWRITE END-SEARCH END-START END-STRING
syn keyword cobolReserved contained END-WRITE EQUAL ERROR ESI EVALUATE EVERY EXCEPTION EXIT
syn keyword cobolReserved contained EXTEND EXTERNAL FALSE FD FILLER FINAL FIRST FOOTING FOR FROM
syn keyword cobolReserved contained GENERATE GIVING GLOBAL GREATER GROUP HEADING HIGH-VALUE HIGH-VALUES I-O
-syn keyword cobolReserved contained IN INDEX INDEXED INDICATE INITIAL INITIALIZE
+syn keyword cobolReserved contained INDEX INDEXED INDICATE INITIAL INITIALIZE
syn keyword cobolReserved contained INITIATE INPUT INSPECT INSTALLATION INTO IS JUST
syn keyword cobolReserved contained JUSTIFIED KEY LABEL LAST LEADING LEFT LENGTH LOCK MEMORY
syn keyword cobolReserved contained MERGE MESSAGE MODE MODULES MOVE MULTIPLE MULTIPLY NATIVE NEGATIVE NEXT NO NOT
syn keyword cobolReserved contained NUMBER NUMERIC NUMERIC-EDITED OCCURS OF OFF OMITTED ON OPEN
syn keyword cobolReserved contained OPTIONAL OR ORDER ORGANIZATION OTHER OUTPUT OVERFLOW PACKED-DECIMAL PADDING
syn keyword cobolReserved contained PAGE PAGE-COUNTER PERFORM PF PH PIC PICTURE PLUS POINTER POSITION POSITIVE
-syn keyword cobolReserved contained PRINTING PROCEDURES PROCEDD PROGRAM PURGE QUEUE QUOTES
+syn keyword cobolReserved contained PRINTING PROCEDURES PROCEDD PURGE QUEUE QUOTES
syn keyword cobolReserved contained RANDOM RD READ RECEIVE RECORD RECORDS REDEFINES REEL REFERENCE REFERENCES
-syn keyword cobolReserved contained RELATIVE RELEASE REMAINDER REMOVAL REPLACE REPLACING REPORT REPORTING
+syn keyword cobolReserved contained RELATIVE RELEASE REMAINDER REMOVAL REPLACE REPORT REPORTING
syn keyword cobolReserved contained REPORTS RERUN RESERVE RESET RETURN RETURNING REVERSED REWIND REWRITE RF RH
syn keyword cobolReserved contained RIGHT ROUNDED RUN SAME SD SEARCH SECTION SECURITY SEGMENT SEGMENT-LIMITED
syn keyword cobolReserved contained SELECT SEND SENTENCE SEPARATE SEQUENCE SEQUENTIAL SET SIGN SIZE SORT
syn keyword cobolReserved contained SORT-MERGE SOURCE STANDARD
syn keyword cobolReserved contained STANDARD-1 STANDARD-2 START STATUS STOP STRING SUB-QUEUE-1 SUB-QUEUE-2
syn keyword cobolReserved contained SUB-QUEUE-3 SUBTRACT SUM SUPPRESS SYMBOLIC SYNC SYNCHRONIZED TABLE TALLYING
-syn keyword cobolReserved contained TAPE TERMINAL TERMINATE TEST TEXT THAN THEN THROUGH THRU TIME TIMES TO TOP
+syn keyword cobolReserved contained TAPE TERMINAL TERMINATE TEST TEXT THAN THEN THROUGH THRU TIME TIMES TOP
syn keyword cobolReserved contained TRAILING TRUE TYPE UNIT UNSTRING UNTIL UP UPON USAGE USE USING VALUE VALUES
syn keyword cobolReserved contained VARYING WHEN WITH WORDS WRITE
syn match cobolReserved contained "\<CONTAINS\>"
syn match cobolReserved contained "\<\(IF\|INVALID\|END\|EOP\)\>"
syn match cobolReserved contained "\<ALL\>"
+" #C22032019: Add BY as match instead of keyword: BY not followed by ==
+syn match cobolReserved contained "\<BY\>\s\+\(==\)\@!"
+syn match cobolReserved contained "\<TO\>"
syn cluster cobolLine add=cobolConstant,cobolNumber,cobolPic
syn keyword cobolConstant SPACE SPACES NULL ZERO ZEROES ZEROS LOW-VALUE LOW-VALUES
+" #C22032019: Fix for many pic clauses
syn match cobolNumber "\<-\=\d*\.\=\d\+\>" contained
-syn match cobolPic "\<S*9\+\>" contained
+" syn match cobolPic \"\<S*9\+\>" contained
+syn match cobolPic "\<S*9\+V*9*\>" contained
syn match cobolPic "\<$*\.\=9\+\>" contained
syn match cobolPic "\<Z*\.\=9\+\>" contained
syn match cobolPic "\<V9\+\>" contained
syn match cobolPic "\<9\+V\>" contained
-syn match cobolPic "\<-\+[Z9]\+\>" contained
-syn match cobolTodo "todo" contained containedin=cobolComment
+" syn match cobolPic \"\<-\+[Z9]\+\>" contained
+syn match cobolPic "\<-*[Z9]\+-*\>" contained
+" #C22032019: Add Z,X and A to cobolPic
+syn match cobolPic "\<[ZXA]\+\>" contained
+syn match cobolTodo "todo" contained containedin=cobolInlineComment,cobolComment
" For MicroFocus or other inline comments, include this line.
-" syn region cobolComment start="*>" end="$" contains=cobolTodo,cobolMarker
+if g:cobol_inline_comment == 1
+ syn region cobolInlineComment start="*>" end="$" contains=cobolTodo,cobolMarker
+ syn cluster cobolLine add=cobolInlineComment
+endif
syn match cobolBadLine "[^ D\*$/-].*" contained
+
" If comment mark somehow gets into column past Column 7.
-syn match cobolBadLine "\s\+\*.*" contained
+if g:cobol_inline_comment == 1
+ " #C22032019: It is a bad line only if * is not followed by > when inline
+ " comments enabled
+ syn match cobolBadLine "\s\+\*\(>\)\@!.*" contained
+else
+ syn match cobolBadLine "\s\+\*.*" contained
+endif
syn cluster cobolStart add=cobolBadLine
-
-syn keyword cobolGoTo GO GOTO
-syn keyword cobolCopy COPY
+" #C22032019: Different highlighting for GO TO statements
+" syn keyword cobolGoTo GO GOTO
+syn keyword cobolGoTo GOTO
+syn match cobolGoTo /\<GO\>\s\+\<TO\>/
+syn match cobolGoToPara /\<GO\>\s\+\<TO\>\s\+[A-Z0-9-]\+/ contains=cobolGoTo
+" #C22032019: Highlight copybook name and location in using different group
+" syn keyword cobolCopy COPY
+syn match cobolCopy "\<COPY\>\|\<IN\>"
+syn match cobolCopy "\<REPLACING\>\s\+\(==\)\@="
+syn match cobolCopy "\<BY\>\s\+\(==\)\@="
+syn match cobolCopyName "\<COPY\>\s\+[A-Z0-9]\+\(\s\+\<IN\>\s\+[A-Z0-9]\+\)\?" contains=cobolCopy
+syn cluster cobolLine add=cobolGoToPara,cobolCopyName
" cobolBAD: things that are BAD NEWS!
syn keyword cobolBAD ALTER ENTER RENAMES
@@ -109,8 +158,14 @@ syn cluster cobolLine add=cobolGoTo,cobolCopy,cobolBAD,cobolWatch,cobolEXE
" cobolWatch: things that are important when trying to understand a program
syn keyword cobolWatch OCCURS DEPENDING VARYING BINARY COMP REDEFINES
-syn keyword cobolWatch REPLACING RUN
-syn match cobolWatch "COMP-[123456XN]"
+" #C22032019: Remove REPLACING from cobolWatch 'keyword' group and add to cobolCopy &
+" cobolWatch 'match' group
+" syn keyword cobolWatch REPLACING RUN
+syn keyword cobolWatch RUN PROGRAM
+syn match cobolWatch contained "\<REPLACING\>\s\+\(==\)\@!"
+" #C22032019: Look for word starting with COMP
+" syn match cobolWatch \"COMP-[123456XN]"
+syn match cobolWatch "\<COMP-[123456XN]"
syn keyword cobolEXECs EXEC END-EXEC
@@ -127,9 +182,15 @@ syn match cobolWatch "88 " contained nextgroup=cobolLine
"syn match cobolBadID "\k\+-\($\|[^-A-Z0-9]\)" contained
syn cluster cobolLine add=cobolCALLs,cobolString,cobolCondFlow
-syn keyword cobolCALLs CALL END-CALL CANCEL GOBACK PERFORM END-PERFORM INVOKE
-syn match cobolCALLs "EXIT \+PROGRAM"
+" #C22032019: Changes for cobolCALLs group to include thru
+" syn keyword cobolCALLs CALL END-CALL CANCEL GOBACK PERFORM END-PERFORM INVOKE
+syn keyword cobolCALLs END-CALL CANCEL GOBACK PERFORM END-PERFORM INVOKE THRU
+" #C22032019: Highlight called program
+" syn match cobolCALLs \"EXIT \+PROGRAM"
+syn match cobolCALLs "\<CALL\>"
+syn match cobolCALLProg /\<CALL\>\s\+"\{0,1\}[A-Z0-9]\+"\{0,1\}/ contains=cobolCALLs
syn match cobolExtras /\<VALUE \+\d\+\./hs=s+6,he=e-1
+syn cluster cobolLine add=cobolCALLProg
syn match cobolString /"[^"]*\("\|$\)/
syn match cobolString /'[^']*\('\|$\)/
@@ -138,7 +199,7 @@ syn match cobolString /'[^']*\('\|$\)/
syn match cobolIndicator "\%7c[D-]" contained
if exists("cobol_legacy_code")
- syn region cobolCondFlow contains=ALLBUT,cobolLine,cobolBadLine start="\<\(IF\|INVALID\|END\|EOP\)\>" skip=/\('\|"\)[^"]\{-}\("\|'\|$\)/ end="\." keepend
+ syn region cobolCondFlow contains=ALLBUT,cobolLine start="\<\(IF\|INVALID\|END\|EOP\)\>" skip=/\('\|"\)[^"]\{-}\("\|'\|$\)/ end="\." keepend
endif
" many legacy sources have junk in columns 1-6: must be before others
@@ -146,7 +207,9 @@ endif
if exists("cobol_legacy_code")
syn match cobolBadLine "\%73c.*" containedin=ALLBUT,cobolComment
else
- syn match cobolBadLine "\%73c.*" containedin=ALL
+ " #C22032019: Use comment highlighting for bad lines
+ " syn match cobolBadLine \"\%73c.*" containedin=ALL
+ syn match cobolBadLine "\%73c.*" containedin=ALL,cobolInlineComment,cobolComment
endif
" Define the default highlighting.
@@ -160,31 +223,36 @@ if exists("g:cobol_legacy_code")
else
hi def link cobolMarker Error
endif
-hi def link cobolCALLs Function
-hi def link cobolComment Comment
-hi def link cobolKeys Comment
-hi def link cobolAreaB Special
-hi def link cobolCompiler PreProc
-hi def link cobolCondFlow Special
-hi def link cobolCopy PreProc
-hi def link cobolDeclA cobolDecl
-hi def link cobolDecl Type
-hi def link cobolExtras Special
-hi def link cobolGoTo Special
-hi def link cobolConstant Constant
-hi def link cobolNumber Constant
-hi def link cobolPic Constant
-hi def link cobolReserved Statement
-hi def link cobolDivision Label
-hi def link cobolSection Label
-hi def link cobolParagraph Label
-hi def link cobolDivisionName Keyword
-hi def link cobolSectionName Keyword
-hi def link cobolParagraphName Keyword
-hi def link cobolString Constant
-hi def link cobolTodo Todo
-hi def link cobolWatch Special
-hi def link cobolIndicator Special
+hi def link cobolCALLs Function
+hi def link cobolCALLProg Special
+hi def link cobolComment Comment
+hi def link cobolInlineComment Comment
+hi def link cobolKeys Comment
+hi def link cobolAreaB Special
+hi def link cobolCompiler PreProc
+hi def link cobolCondFlow Special
+hi def link cobolCopy PreProc
+hi def link cobolCopyName Special
+hi def link cobolDeclA cobolDecl
+hi def link cobolDecl Type
+hi def link cobolExtras Special
+hi def link cobolGoTo Special
+hi def link cobolGoToPara Function
+hi def link cobolConstant Constant
+hi def link cobolNumber Constant
+hi def link cobolPic Constant
+hi def link cobolReserved Statement
+hi def link cobolDivision Label
+hi def link cobolSection Label
+hi def link cobolParagraph Label
+hi def link cobolDivisionName Keyword
+hi def link cobolSectionName Keyword
+hi def link cobolParagraphName Keyword
+hi def link cobolString Constant
+hi def link cobolTodo Todo
+hi def link cobolWatch Special
+hi def link cobolIndicator Special
+hi def link cobolStart Comment
let b:current_syntax = "cobol"
diff --git a/runtime/syntax/dcl.vim b/runtime/syntax/dcl.vim
index b973db3434..c0d0ebcf95 100644
--- a/runtime/syntax/dcl.vim
+++ b/runtime/syntax/dcl.vim
@@ -1,8 +1,8 @@
" Vim syntax file
" Language: DCL (Digital Command Language - vms)
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
-" Last Change: Aug 31, 2016
-" Version: 11
+" Last Change: Mar 26, 2019
+" Version: 12
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_DCL
" quit when a syntax file was already loaded
@@ -10,10 +10,10 @@ if exists("b:current_syntax")
finish
endif
-if !has("patch-7.4.1142")
- setlocal iskeyword=$,@,48-57,_
-else
+if (v:version == 704 && has("patch-7.4.1142")) || v:version > 704
syn iskeyword $,@,48-57,_
+else
+ setlocal iskeyword=$,@,48-57,_
endif
syn case ignore
diff --git a/runtime/syntax/debchangelog.vim b/runtime/syntax/debchangelog.vim
index 4ca4c299b2..9d6dfe96a5 100644
--- a/runtime/syntax/debchangelog.vim
+++ b/runtime/syntax/debchangelog.vim
@@ -3,7 +3,7 @@
" Maintainer: Debian Vim Maintainers
" Former Maintainers: Gerfried Fuchs <alfie@ist.org>
" Wichert Akkerman <wakkerma@debian.org>
-" Last Change: 2019 Jan 26
+" Last Change: 2019 Apr 21
" URL: https://salsa.debian.org/vim-team/vim-debian/blob/master/syntax/debchangelog.vim
" Standard syntax initialization
@@ -21,7 +21,7 @@ let s:binNMU='binary-only=yes'
syn match debchangelogName contained "^[[:alnum:]][[:alnum:].+-]\+ "
exe 'syn match debchangelogFirstKV contained "; \('.s:urgency.'\|'.s:binNMU.'\)"'
exe 'syn match debchangelogOtherKV contained ", \('.s:urgency.'\|'.s:binNMU.'\)"'
-syn match debchangelogTarget contained "\v %(frozen|unstable|sid|%(testing|%(old)=stable)%(-proposed-updates|-security)=|experimental|squeeze-%(backports%(-sloppy)=|volatile|lts|security)|%(wheezy|jessie)%(-backports%(-sloppy)=|-security)=|stretch%(-backports|-security)=|%(devel|precise|trusty|vivid|wily|xenial|yakkety|zesty|artful|bionic|cosmic|disco)%(-%(security|proposed|updates|backports|commercial|partner))=)+"
+syn match debchangelogTarget contained "\v %(frozen|unstable|sid|%(testing|%(old)=stable)%(-proposed-updates|-security)=|experimental|%(squeeze|wheezy|jessie)-%(backports%(-sloppy)=|lts|security)|stretch%(-backports%(-sloppy)=|-security)=|buster%(-backports|-security)=|bullseye|%(devel|precise|trusty|vivid|wily|xenial|yakkety|zesty|artful|bionic|cosmic|disco|eoan)%(-%(security|proposed|updates|backports|commercial|partner))=)+"
syn match debchangelogVersion contained "(.\{-})"
syn match debchangelogCloses contained "closes:\_s*\(bug\)\=#\=\_s\=\d\+\(,\_s*\(bug\)\=#\=\_s\=\d\+\)*"
syn match debchangelogLP contained "\clp:\s\+#\d\+\(,\s*#\d\+\)*"
diff --git a/runtime/syntax/debsources.vim b/runtime/syntax/debsources.vim
index 4b2194125d..f90476fe25 100644
--- a/runtime/syntax/debsources.vim
+++ b/runtime/syntax/debsources.vim
@@ -2,7 +2,7 @@
" Language: Debian sources.list
" Maintainer: Debian Vim Maintainers
" Former Maintainer: Matthijs Mohlmann <matthijs@cacholong.nl>
-" Last Change: 2018 Oct 30
+" Last Change: 2019 Apr 21
" URL: https://salsa.debian.org/vim-team/vim-debian/blob/master/syntax/debsources.vim
" Standard syntax initialization
@@ -23,9 +23,10 @@ let s:cpo = &cpo
set cpo-=C
let s:supported = [
\ 'oldstable', 'stable', 'testing', 'unstable', 'experimental',
- \ 'wheezy', 'jessie', 'stretch', 'sid', 'rc-buggy',
+ \ 'wheezy', 'jessie', 'stretch', 'buster', 'bullseye', 'bookworm',
+ \ 'sid', 'rc-buggy',
\
- \ 'trusty', 'xenial', 'bionic', 'cosmic', 'disco', 'devel'
+ \ 'trusty', 'xenial', 'bionic', 'cosmic', 'disco', 'eoan', 'devel'
\ ]
let s:unsupported = [
\ 'buzz', 'rex', 'bo', 'hamm', 'slink', 'potato',
diff --git a/runtime/syntax/html.vim b/runtime/syntax/html.vim
index cde5269d02..d16ee1817f 100644
--- a/runtime/syntax/html.vim
+++ b/runtime/syntax/html.vim
@@ -3,8 +3,8 @@
" Maintainer: Jorge Maldonado Ventura <jorgesumle@freakspot.net>
" Previous Maintainer: Claudio Fleiner <claudio@fleiner.com>
" Repository: https://notabug.org/jorgesumle/vim-html-syntax
-" Last Change: 2018 May 31
-" Included patch from Jay Sitter to add WAI-ARIA htmlArg keywords
+" Last Change: 2018 Apr 7
+" Included patch from Jorge Maldonado Ventura to fix rendering
"
" Please check :help html.vim for some comments and a description of the options
@@ -159,47 +159,47 @@ if !exists("html_no_rendering")
" rendering
syn cluster htmlTop contains=@Spell,htmlTag,htmlEndTag,htmlSpecialChar,htmlPreProc,htmlComment,htmlLink,javaScript,@htmlPreproc
- syn region htmlStrike start="<del\>" end="</del>"me=e-6 contains=@htmlTop
- syn region htmlStrike start="<strike\>" end="</strike>"me=e-9 contains=@htmlTop
-
- syn region htmlBold start="<b\>" end="</b>"me=e-4 contains=@htmlTop,htmlBoldUnderline,htmlBoldItalic
- syn region htmlBold start="<strong\>" end="</strong>"me=e-9 contains=@htmlTop,htmlBoldUnderline,htmlBoldItalic
- syn region htmlBoldUnderline contained start="<u\>" end="</u>"me=e-4 contains=@htmlTop,htmlBoldUnderlineItalic
- syn region htmlBoldItalic contained start="<i\>" end="</i>"me=e-4 contains=@htmlTop,htmlBoldItalicUnderline
- syn region htmlBoldItalic contained start="<em\>" end="</em>"me=e-5 contains=@htmlTop,htmlBoldItalicUnderline
- syn region htmlBoldUnderlineItalic contained start="<i\>" end="</i>"me=e-4 contains=@htmlTop
- syn region htmlBoldUnderlineItalic contained start="<em\>" end="</em>"me=e-5 contains=@htmlTop
- syn region htmlBoldItalicUnderline contained start="<u\>" end="</u>"me=e-4 contains=@htmlTop,htmlBoldUnderlineItalic
-
- syn region htmlUnderline start="<u\>" end="</u>"me=e-4 contains=@htmlTop,htmlUnderlineBold,htmlUnderlineItalic
- syn region htmlUnderlineBold contained start="<b\>" end="</b>"me=e-4 contains=@htmlTop,htmlUnderlineBoldItalic
- syn region htmlUnderlineBold contained start="<strong\>" end="</strong>"me=e-9 contains=@htmlTop,htmlUnderlineBoldItalic
- syn region htmlUnderlineItalic contained start="<i\>" end="</i>"me=e-4 contains=@htmlTop,htmlUnderlineItalicBold
- syn region htmlUnderlineItalic contained start="<em\>" end="</em>"me=e-5 contains=@htmlTop,htmlUnderlineItalicBold
- syn region htmlUnderlineItalicBold contained start="<b\>" end="</b>"me=e-4 contains=@htmlTop
- syn region htmlUnderlineItalicBold contained start="<strong\>" end="</strong>"me=e-9 contains=@htmlTop
- syn region htmlUnderlineBoldItalic contained start="<i\>" end="</i>"me=e-4 contains=@htmlTop
- syn region htmlUnderlineBoldItalic contained start="<em\>" end="</em>"me=e-5 contains=@htmlTop
-
- syn region htmlItalic start="<i\>" end="</i>"me=e-4 contains=@htmlTop,htmlItalicBold,htmlItalicUnderline
- syn region htmlItalic start="<em\>" end="</em>"me=e-5 contains=@htmlTop
- syn region htmlItalicBold contained start="<b\>" end="</b>"me=e-4 contains=@htmlTop,htmlItalicBoldUnderline
- syn region htmlItalicBold contained start="<strong\>" end="</strong>"me=e-9 contains=@htmlTop,htmlItalicBoldUnderline
- syn region htmlItalicBoldUnderline contained start="<u\>" end="</u>"me=e-4 contains=@htmlTop
- syn region htmlItalicUnderline contained start="<u\>" end="</u>"me=e-4 contains=@htmlTop,htmlItalicUnderlineBold
- syn region htmlItalicUnderlineBold contained start="<b\>" end="</b>"me=e-4 contains=@htmlTop
- syn region htmlItalicUnderlineBold contained start="<strong\>" end="</strong>"me=e-9 contains=@htmlTop
+ syn region htmlStrike start="<del\>" end="</del\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlStrike start="<strike\>" end="</strike\_s*>"me=s-1 contains=@htmlTop
+
+ syn region htmlBold start="<b\>" end="</b\_s*>"me=s-1 contains=@htmlTop,htmlBoldUnderline,htmlBoldItalic
+ syn region htmlBold start="<strong\>" end="</strong\_s*>"me=s-1 contains=@htmlTop,htmlBoldUnderline,htmlBoldItalic
+ syn region htmlBoldUnderline contained start="<u\>" end="</u\_s*>"me=s-1 contains=@htmlTop,htmlBoldUnderlineItalic
+ syn region htmlBoldItalic contained start="<i\>" end="</i\_s*>"me=s-1 contains=@htmlTop,htmlBoldItalicUnderline
+ syn region htmlBoldItalic contained start="<em\>" end="</em\_s*>"me=s-1 contains=@htmlTop,htmlBoldItalicUnderline
+ syn region htmlBoldUnderlineItalic contained start="<i\>" end="</i\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlBoldUnderlineItalic contained start="<em\>" end="</em\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlBoldItalicUnderline contained start="<u\>" end="</u\_s*>"me=s-1 contains=@htmlTop,htmlBoldUnderlineItalic
+
+ syn region htmlUnderline start="<u\>" end="</u\_s*>"me=s-1 contains=@htmlTop,htmlUnderlineBold,htmlUnderlineItalic
+ syn region htmlUnderlineBold contained start="<b\>" end="</b\_s*>"me=s-1 contains=@htmlTop,htmlUnderlineBoldItalic
+ syn region htmlUnderlineBold contained start="<strong\>" end="</strong\_s*>"me=s-1 contains=@htmlTop,htmlUnderlineBoldItalic
+ syn region htmlUnderlineItalic contained start="<i\>" end="</i\_s*>"me=s-1 contains=@htmlTop,htmlUnderlineItalicBold
+ syn region htmlUnderlineItalic contained start="<em\>" end="</em\_s*>"me=s-1 contains=@htmlTop,htmlUnderlineItalicBold
+ syn region htmlUnderlineItalicBold contained start="<b\>" end="</b\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlUnderlineItalicBold contained start="<strong\>" end="</strong\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlUnderlineBoldItalic contained start="<i\>" end="</i\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlUnderlineBoldItalic contained start="<em\>" end="</em\_s*>"me=s-1 contains=@htmlTop
+
+ syn region htmlItalic start="<i\>" end="</i\_s*>"me=s-1 contains=@htmlTop,htmlItalicBold,htmlItalicUnderline
+ syn region htmlItalic start="<em\>" end="</em\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlItalicBold contained start="<b\>" end="</b\_s*>"me=s-1 contains=@htmlTop,htmlItalicBoldUnderline
+ syn region htmlItalicBold contained start="<strong\>" end="</strong\_s*>"me=s-1 contains=@htmlTop,htmlItalicBoldUnderline
+ syn region htmlItalicBoldUnderline contained start="<u\>" end="</u\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlItalicUnderline contained start="<u\>" end="</u\_s*>"me=s-1 contains=@htmlTop,htmlItalicUnderlineBold
+ syn region htmlItalicUnderlineBold contained start="<b\>" end="</b\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlItalicUnderlineBold contained start="<strong\>" end="</strong\_s*>"me=s-1 contains=@htmlTop
syn match htmlLeadingSpace "^\s\+" contained
- syn region htmlLink start="<a\>\_[^>]*\<href\>" end="</a>"me=e-4 contains=@Spell,htmlTag,htmlEndTag,htmlSpecialChar,htmlPreProc,htmlComment,htmlLeadingSpace,javaScript,@htmlPreproc
- syn region htmlH1 start="<h1\>" end="</h1>"me=e-5 contains=@htmlTop
- syn region htmlH2 start="<h2\>" end="</h2>"me=e-5 contains=@htmlTop
- syn region htmlH3 start="<h3\>" end="</h3>"me=e-5 contains=@htmlTop
- syn region htmlH4 start="<h4\>" end="</h4>"me=e-5 contains=@htmlTop
- syn region htmlH5 start="<h5\>" end="</h5>"me=e-5 contains=@htmlTop
- syn region htmlH6 start="<h6\>" end="</h6>"me=e-5 contains=@htmlTop
- syn region htmlHead start="<head\>" end="</head>"me=e-7 end="<body\>"me=e-5 end="<h[1-6]\>"me=e-3 contains=htmlTag,htmlEndTag,htmlSpecialChar,htmlPreProc,htmlComment,htmlLink,htmlTitle,javaScript,cssStyle,@htmlPreproc
- syn region htmlTitle start="<title\>" end="</title>"me=e-8 contains=htmlTag,htmlEndTag,htmlSpecialChar,htmlPreProc,htmlComment,javaScript,@htmlPreproc
+ syn region htmlLink start="<a\>\_[^>]*\<href\>" end="</a\_s*>"me=s-1 contains=@Spell,htmlTag,htmlEndTag,htmlSpecialChar,htmlPreProc,htmlComment,htmlLeadingSpace,javaScript,@htmlPreproc
+ syn region htmlH1 start="<h1\>" end="</h1\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlH2 start="<h2\>" end="</h2\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlH3 start="<h3\>" end="</h3\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlH4 start="<h4\>" end="</h4\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlH5 start="<h5\>" end="</h5\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlH6 start="<h6\>" end="</h6\_s*>"me=s-1 contains=@htmlTop
+ syn region htmlHead start="<head\>" end="</head\_s*>"me=s-1 end="<body\>"me=s-1 end="<h[1-6]\>"me=s-1 contains=htmlTag,htmlEndTag,htmlSpecialChar,htmlPreProc,htmlComment,htmlLink,htmlTitle,javaScript,cssStyle,@htmlPreproc
+ syn region htmlTitle start="<title\>" end="</title\_s*>"me=s-1 contains=htmlTag,htmlEndTag,htmlSpecialChar,htmlPreProc,htmlComment,javaScript,@htmlPreproc
endif
syn keyword htmlTagName contained noscript
diff --git a/runtime/syntax/lisp.vim b/runtime/syntax/lisp.vim
index b6aa04b2c7..d99e032bbf 100644
--- a/runtime/syntax/lisp.vim
+++ b/runtime/syntax/lisp.vim
@@ -1,8 +1,8 @@
" Vim syntax file
" Language: Lisp
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
-" Last Change: Feb 15, 2018
-" Version: 27
+" Last Change: Mar 26, 2019
+" Version: 28
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_LISP
"
" Thanks to F Xavier Noria for a list of 978 Common Lisp symbols taken from HyperSpec
@@ -16,10 +16,10 @@ endif
if exists("g:lisp_isk")
exe "setl isk=".g:lisp_isk
-elseif !has("patch-7.4.1142")
- setl isk=38,42,43,45,47-58,60-62,64-90,97-122,_
-else
+elseif (v:version == 704 && has("patch-7.4.1142")) || v:version > 704
syn iskeyword 38,42,43,45,47-58,60-62,64-90,97-122,_
+else
+ setl isk=38,42,43,45,47-58,60-62,64-90,97-122,_
endif
if exists("g:lispsyntax_ignorecase") || exists("g:lispsyntax_clisp")
diff --git a/runtime/syntax/make.vim b/runtime/syntax/make.vim
index 7072bab988..377e4450d9 100644
--- a/runtime/syntax/make.vim
+++ b/runtime/syntax/make.vim
@@ -1,8 +1,9 @@
" Vim syntax file
" Language: Makefile
-" Maintainer: Claudio Fleiner <claudio@fleiner.com>
-" URL: http://www.fleiner.com/vim/syntax/make.vim
-" Last Change: 2015 Feb 28
+" Maintainer: Roland Hieber <rohieb+vim-iR0jGdkV@rohieb.name>
+" Previous Maintainer: Claudio Fleiner <claudio@fleiner.com>
+" URL: https://github.com/vim/vim/syntax/make.vim
+" Last Change: 2019 Apr 02
" quit when a syntax file was already loaded
if exists("b:current_syntax")
@@ -18,7 +19,7 @@ syn match makeSpecial "^\s*[@+-]\+"
syn match makeNextLine "\\\n\s*"
" some directives
-syn match makePreCondit "^ *\(ifeq\>\|else\>\|endif\>\|ifneq\>\|ifdef\>\|ifndef\>\)"
+syn match makePreCondit "^ *\(ifn\=\(eq\|def\)\>\|else\(\s\+ifn\=\(eq\|def\)\)\=\>\|endif\>\)"
syn match makeInclude "^ *[-s]\=include"
syn match makeStatement "^ *vpath"
syn match makeExport "^ *\(export\|unexport\)\>"
@@ -31,8 +32,8 @@ syn region makeDefine start="^\s*define\s" end="^\s*endef\s*\(#.*\)\?$" contains
" Microsoft Makefile specials
syn case ignore
-syn match makeInclude "^! *include"
-syn match makePreCondit "! *\(cmdswitches\|error\|message\|include\|if\|ifdef\|ifndef\|else\|elseif\|else if\|else\s*ifdef\|else\s*ifndef\|endif\|undef\)\>"
+syn match makeInclude "^!\s*include"
+syn match makePreCondit "^!\s*\(cmdswitches\|error\|message\|include\|if\|ifdef\|ifndef\|else\|else\s*if\|else\s*ifdef\|else\s*ifndef\|endif\|undef\)\>"
syn case match
" identifiers
@@ -64,7 +65,7 @@ syn match makeCmdNextLine "\\\n."he=e-1 contained
" Statements / Functions (GNU make)
-syn match makeStatement contained "(\(subst\|abspath\|addprefix\|addsuffix\|and\|basename\|call\|dir\|error\|eval\|filter-out\|filter\|findstring\|firstword\|flavor\|foreach\|if\|info\|join\|lastword\|notdir\|or\|origin\|patsubst\|realpath\|shell\|sort\|strip\|suffix\|value\|warning\|wildcard\|word\|wordlist\|words\)\>"ms=s+1
+syn match makeStatement contained "(\(abspath\|addprefix\|addsuffix\|and\|basename\|call\|dir\|error\|eval\|file\|filter-out\|filter\|findstring\|firstword\|flavor\|foreach\|guile\|if\|info\|join\|lastword\|notdir\|or\|origin\|patsubst\|realpath\|shell\|sort\|strip\|subst\|suffix\|value\|warning\|wildcard\|word\|wordlist\|words\)\>"ms=s+1
" Comment
if exists("make_microsoft")
@@ -100,17 +101,17 @@ syn sync match makeCommandSync groupthere makeCommands "^[A-Za-z0-9_./$()%-][A-Z
" Define the default highlighting.
" Only when an item doesn't have highlighting yet
-hi def link makeNextLine makeSpecial
+hi def link makeNextLine makeSpecial
hi def link makeCmdNextLine makeSpecial
-hi def link makeSpecTarget Statement
+hi def link makeSpecTarget Statement
if !exists("make_no_commands")
-hi def link makeCommands Number
+hi def link makeCommands Number
endif
-hi def link makeImplicit Function
+hi def link makeImplicit Function
hi def link makeTarget Function
hi def link makeInclude Include
-hi def link makePreCondit PreCondit
-hi def link makeStatement Statement
+hi def link makePreCondit PreCondit
+hi def link makeStatement Statement
hi def link makeIdent Identifier
hi def link makeSpecial Special
hi def link makeComment Comment
diff --git a/runtime/syntax/maple.vim b/runtime/syntax/maple.vim
index 1261ff5a47..f14cf79cf4 100644
--- a/runtime/syntax/maple.vim
+++ b/runtime/syntax/maple.vim
@@ -1,8 +1,8 @@
" Vim syntax file
" Language: Maple V (based on release 4)
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
-" Last Change: Aug 31, 2016
-" Version: 15
+" Last Change: Mar 26, 2019
+" Version: 16
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_MAPLE
"
" Package Function Selection: {{{1
@@ -27,10 +27,10 @@ if exists("b:current_syntax")
endif
" Iskeyword Effects: {{{1
-if !has("patch-7.4.1142")
- setl isk=$,48-57,_,a-z,@-Z
-else
+if (v:version == 704 && has("patch-7.4.1142")) || v:version > 704
syn iskeyword $,48-57,_,a-z,@-Z
+else
+ setl isk=$,48-57,_,a-z,@-Z
endif
" Package Selection: {{{1
diff --git a/runtime/syntax/rmd.vim b/runtime/syntax/rmd.vim
index a26389024d..d852d225bc 100644
--- a/runtime/syntax/rmd.vim
+++ b/runtime/syntax/rmd.vim
@@ -1,7 +1,7 @@
" markdown Text with R statements
" Language: markdown with R code chunks
" Homepage: https://github.com/jalvesaq/R-Vim-runtime
-" Last Change: Sat Aug 25, 2018 03:44PM
+" Last Change: Thu Apr 18, 2019 09:17PM
"
" For highlighting pandoc extensions to markdown like citations and TeX and
" many other advanced features like folding of markdown sections, it is
@@ -54,14 +54,14 @@ runtime syntax/markdown.vim
" Now highlight chunks:
for s:type in g:rmd_fenced_languages
if s:type =~ '='
- let s:lng = substitute(s:type, '=.*', '')
- let s:nm = substitute(s:type, '.*=', '')
+ let s:ft = substitute(s:type, '.*=', '', '')
+ let s:nm = substitute(s:type, '=.*', '', '')
else
- let s:lng = s:type
+ let s:ft = s:type
let s:nm = s:type
endif
unlet! b:current_syntax
- exe 'syn include @Rmd'.s:nm.' syntax/'.s:lng.'.vim'
+ exe 'syn include @Rmd'.s:nm.' syntax/'.s:ft.'.vim'
if g:rmd_syn_hl_chunk
exe 'syn region rmd'.s:nm.'ChunkDelim matchgroup=rmdCodeDelim start="^\s*```\s*{\s*'.s:nm.'\>" matchgroup=rmdCodeDelim end="}$" keepend containedin=rmd'.s:nm.'Chunk contains=@Rmd'.s:nm
exe 'syn region rmd'.s:nm.'Chunk start="^\s*```\s*{\s*'.s:nm.'\>.*$" matchgroup=rmdCodeDelim end="^\s*```\ze\s*$" keepend contains=rmd'.s:nm.'ChunkDelim,@Rmd'.s:nm
diff --git a/runtime/syntax/sh.vim b/runtime/syntax/sh.vim
index 9eed594b8c..b9c71de4c4 100644
--- a/runtime/syntax/sh.vim
+++ b/runtime/syntax/sh.vim
@@ -2,8 +2,8 @@
" Language: shell (sh) Korn shell (ksh) bash (sh)
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
" Previous Maintainer: Lennart Schultz <Lennart.Schultz@ecmwf.int>
-" Last Change: Nov 23, 2018
-" Version: 185
+" Last Change: Mar 26, 2019
+" Version: 186
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_SH
" For options and settings, please use: :help ft-sh-syntax
" This file includes many ideas from Eric Brunet (eric.brunet@ens.fr)
@@ -89,7 +89,7 @@ if g:sh_fold_enabled && &fdm == "manual"
endif
" set up the syntax-highlighting iskeyword
-if has("patch-7.4.1142")
+if (v:version == 704 && has("patch-7.4.1142")) || v:version > 704
if exists("b:is_bash")
exe "syn iskeyword ".&iskeyword.",-,:"
else
diff --git a/runtime/syntax/spec.vim b/runtime/syntax/spec.vim
index 3a7dc9e422..2d2550559b 100644
--- a/runtime/syntax/spec.vim
+++ b/runtime/syntax/spec.vim
@@ -3,7 +3,7 @@
" Language: SPEC: Build/install scripts for Linux RPM packages
" Maintainer: Igor Gnatenko i.gnatenko.brain@gmail.com
" Former Maintainer: Donovan Rebbechi elflord@panix.com (until March 2014)
-" Last Change: Sat Apr 9 15:30 2016 Filip Szymański
+" Last Change: 2019 May 07
" quit when a syntax file was already loaded
if exists("b:current_syntax")
@@ -86,9 +86,9 @@ syn region specSectionMacroBracketArea oneline matchgroup=specSectionMacro start
"%% Files Section %%
"TODO %config valid parameters: missingok\|noreplace
"TODO %verify valid parameters: \(not\)\= \(md5\|atime\|...\)
-syn region specFilesArea matchgroup=specSection start='^%[Ff][Ii][Ll][Ee][Ss]\>' skip='%\(attrib\|defattr\|attr\|dir\|config\|docdir\|doc\|lang\|verify\|ghost\)\>' end='^%[a-zA-Z]'me=e-2 contains=specFilesOpts,specFilesDirective,@specListedFiles,specComment,specCommandSpecial,specMacroIdentifier
+syn region specFilesArea matchgroup=specSection start='^%[Ff][Ii][Ll][Ee][Ss]\>' skip='%\(attrib\|defattr\|attr\|dir\|config\|docdir\|doc\|lang\|license\|verify\|ghost\|exclude\)\>' end='^%[a-zA-Z]'me=e-2 contains=specFilesOpts,specFilesDirective,@specListedFiles,specComment,specCommandSpecial,specMacroIdentifier
"tip: remember to include new itens in specFilesArea above
-syn match specFilesDirective contained '%\(attrib\|defattr\|attr\|dir\|config\|docdir\|doc\|lang\|verify\|ghost\)\>'
+syn match specFilesDirective contained '%\(attrib\|defattr\|attr\|dir\|config\|docdir\|doc\|lang\|license\|verify\|ghost\|exclude\)\>'
"valid options for certain section headers
syn match specDescriptionOpts contained '\s-[ln]\s*\a'ms=s+1,me=e-1
diff --git a/runtime/syntax/template.vim b/runtime/syntax/template.vim
new file mode 100644
index 0000000000..5bf580fc11
--- /dev/null
+++ b/runtime/syntax/template.vim
@@ -0,0 +1,15 @@
+" Vim syntax file
+" Language: Generic template
+" Maintainer: Bram Moolenaar <Bram@vim.org>
+" Last Change: 2019 May 06
+
+" Quit when a (custom) syntax file was already loaded
+if exists("b:current_syntax")
+ finish
+endif
+
+" Known template types are very similar to HTML, E.g. golang and "Xfire User
+" Interface Template"
+" If you know how to recognize a more specific type for *.tmpl suggest a
+" change to runtime/scripts.vim.
+runtime! syntax/html.vim
diff --git a/runtime/syntax/tex.vim b/runtime/syntax/tex.vim
index 3969cd4777..6381028de5 100644
--- a/runtime/syntax/tex.vim
+++ b/runtime/syntax/tex.vim
@@ -1,8 +1,8 @@
" Vim syntax file
" Language: TeX
" Maintainer: Charles E. Campbell <NdrchipO@ScampbellPfamily.AbizM>
-" Last Change: Nov 02, 2018
-" Version: 111
+" Last Change: Apr 01, 2019
+" Version: 113
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_TEX
"
" Notes: {{{1
@@ -127,7 +127,7 @@ elseif b:tex_stylish
else
let b:tex_isk="48-57,a-z,A-Z,192-255"
endif
-if v:version > 704 || (v:version == 704 && has("patch-7.4.1142"))
+if (v:version == 704 && has("patch-7.4.1142")) || v:version > 704
exe "syn iskeyword ".b:tex_isk
else
exe "setl isk=".b:tex_isk
@@ -155,9 +155,9 @@ if !s:tex_no_error
syn cluster texCmdGroup add=texMathError
endif
syn cluster texEnvGroup contains=texMatcher,texMathDelim,texSpecialChar,texStatement
-syn cluster texFoldGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texInputFile,texLength,texLigature,texMatcher,texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ,texNewCmd,texNewEnv,texOnlyMath,texOption,texParen,texRefZone,texSection,texBeginEnd,texSectionZone,texSpaceCode,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,@texMathZones,texTitle,texAbstract,texBoldStyle,texItalStyle,texNoSpell
+syn cluster texFoldGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texInputFile,texLength,texLigature,texMatcher,texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ,texNewCmd,texNewEnv,texOnlyMath,texOption,texParen,texRefZone,texSection,texBeginEnd,texSectionZone,texSpaceCode,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,@texMathZones,texTitle,texAbstract,texBoldStyle,texItalStyle,texEmphStyle,texNoSpell
syn cluster texBoldGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texInputFile,texLength,texLigature,texMatcher,texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ,texNewCmd,texNewEnv,texOnlyMath,texOption,texParen,texRefZone,texSection,texBeginEnd,texSectionZone,texSpaceCode,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,@texMathZones,texTitle,texAbstract,texBoldStyle,texBoldItalStyle,texNoSpell
-syn cluster texItalGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texInputFile,texLength,texLigature,texMatcher,texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ,texNewCmd,texNewEnv,texOnlyMath,texOption,texParen,texRefZone,texSection,texBeginEnd,texSectionZone,texSpaceCode,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,@texMathZones,texTitle,texAbstract,texItalStyle,texItalBoldStyle,texNoSpell
+syn cluster texItalGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texInputFile,texLength,texLigature,texMatcher,texMathZoneV,texMathZoneW,texMathZoneX,texMathZoneY,texMathZoneZ,texNewCmd,texNewEnv,texOnlyMath,texOption,texParen,texRefZone,texSection,texBeginEnd,texSectionZone,texSpaceCode,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texZone,@texMathZones,texTitle,texAbstract,texItalStyle,texEmphStyle,texItalBoldStyle,texNoSpell
if !s:tex_nospell
syn cluster texMatchGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMatcher,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texBoldStyle,texBoldItalStyle,texItalStyle,texItalBoldStyle,texZone,texInputFile,texOption,@Spell
syn cluster texMatchNMGroup contains=texAccent,texBadMath,texComment,texDefCmd,texDelimiter,texDocType,texInput,texLength,texLigature,texMatcherNM,texNewCmd,texNewEnv,texOnlyMath,texParen,texRefZone,texSection,texSpecialChar,texStatement,texString,texTypeSize,texTypeStyle,texBoldStyle,texBoldItalStyle,texItalStyle,texItalBoldStyle,texZone,texInputFile,texOption,@Spell
@@ -301,6 +301,7 @@ syn match texTypeStyle "\\tt\>"
if s:tex_conceal !~# 'b'
syn match texTypeStyle "\\textbf\>"
syn match texTypeStyle "\\textit\>"
+ syn match texTypeStyle "\\emph\>"
endif
syn match texTypeStyle "\\textmd\>"
syn match texTypeStyle "\\textrm\>"
@@ -309,7 +310,6 @@ syn match texTypeStyle "\\textsf\>"
syn match texTypeStyle "\\textsl\>"
syn match texTypeStyle "\\texttt\>"
syn match texTypeStyle "\\textup\>"
-syn match texTypeStyle "\\emph\>"
syn match texTypeStyle "\\mathbb\>"
syn match texTypeStyle "\\mathbf\>"
@@ -385,11 +385,13 @@ if s:tex_fast =~# 'b'
syn region texBoldItalStyle matchgroup=texTypeStyle start="\\textit\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup,@Spell
syn region texItalStyle matchgroup=texTypeStyle start="\\textit\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup,@Spell
syn region texItalBoldStyle matchgroup=texTypeStyle start="\\textbf\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texBoldGroup,@Spell
+ syn region texEmphStyle matchgroup=texTypeStyle start="\\emph\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup,@Spell
else
syn region texBoldStyle matchgroup=texTypeStyle start="\\textbf\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texBoldGroup
syn region texBoldItalStyle matchgroup=texTypeStyle start="\\textit\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup
syn region texItalStyle matchgroup=texTypeStyle start="\\textit\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup
syn region texItalBoldStyle matchgroup=texTypeStyle start="\\textbf\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texBoldGroup
+ syn region texEmphStyle matchgroup=texTypeStyle start="\\emph\s*{" matchgroup=texTypeStyle end="}" concealends contains=@texItalGroup
endif
endif
endif
@@ -790,6 +792,8 @@ if has("conceal") && &enc == 'utf-8'
\ ['propto' , '∝'],
\ ['rceil' , '⌉'],
\ ['Re' , 'ℜ'],
+ \ ['quad' , ' '],
+ \ ['qquad' , ' '],
\ ['rfloor' , '⌋'],
\ ['right)' , ')'],
\ ['right]' , ']'],
@@ -1228,6 +1232,7 @@ if !exists("skip_tex_syntax_inits")
hi texItalStyle gui=italic cterm=italic
hi texBoldItalStyle gui=bold,italic cterm=bold,italic
hi texItalBoldStyle gui=bold,italic cterm=bold,italic
+ hi def link texEmphStyle texItalStyle
hi def link texCite texRefZone
hi def link texDefCmd texDef
hi def link texDefName texDef
diff --git a/runtime/syntax/vim.vim b/runtime/syntax/vim.vim
index 31e81c76f8..9544de4e07 100644
--- a/runtime/syntax/vim.vim
+++ b/runtime/syntax/vim.vim
@@ -193,7 +193,7 @@ syn keyword vimAugroupKey contained aug[roup]
" =========
syn cluster vimOperGroup contains=vimEnvvar,vimFunc,vimFuncVar,vimOper,vimOperParen,vimNumber,vimString,vimRegister,vimContinue
syn match vimOper "\%#=1\(==\|!=\|>=\|<=\|=\~\|!\~\|>\|<\|=\)[?#]\{0,2}" skipwhite nextgroup=vimString,vimSpecFile
-syn match vimOper "\(\<is\>\|\<isnot\>\)[?#]\{0,2}" skipwhite nextgroup=vimString,vimSpecFile
+syn match vimOper "\(\<is\|\<isnot\)[?#]\{0,2}\>" skipwhite nextgroup=vimString,vimSpecFile
syn match vimOper "||\|&&\|[-+.]" skipwhite nextgroup=vimString,vimSpecFile
syn region vimOperParen matchgroup=vimParenSep start="(" end=")" contains=@vimOperGroup
syn region vimOperParen matchgroup=vimSep start="{" end="}" contains=@vimOperGroup nextgroup=vimVar,vimFuncVar
diff --git a/runtime/syntax/yacc.vim b/runtime/syntax/yacc.vim
index 8d5eb13071..3f27bce443 100644
--- a/runtime/syntax/yacc.vim
+++ b/runtime/syntax/yacc.vim
@@ -1,8 +1,8 @@
" Vim syntax file
" Language: Yacc
" Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz>
-" Last Change: Aug 31, 2016
-" Version: 15
+" Last Change: Mar 25, 2019
+" Version: 16
" URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_YACC
"
" Options: {{{1
@@ -43,12 +43,12 @@ syn cluster yaccRulesCluster contains=yaccNonterminal,yaccString
" ---------------------------------------------------------------------
" Yacc Sections: {{{1
-SynFold syn region yaccInit start='.'ms=s-1,rs=s-1 matchgroup=yaccSectionSep end='^%%$'me=e-2,re=e-2 contains=@yaccInitCluster nextgroup=yaccRules skipwhite skipempty contained
-SynFold syn region yaccInit2 start='\%^.'ms=s-1,rs=s-1 matchgroup=yaccSectionSep end='^%%$'me=e-2,re=e-2 contains=@yaccInitCluster nextgroup=yaccRules skipwhite skipempty
-SynFold syn region yaccHeader2 matchgroup=yaccSep start="^\s*\zs%{" end="^\s*%}" contains=@yaccCode nextgroup=yaccInit skipwhite skipempty contained
-SynFold syn region yaccHeader matchgroup=yaccSep start="^\s*\zs%{" end="^\s*%}" contains=@yaccCode nextgroup=yaccInit skipwhite skipempty
-SynFold syn region yaccRules matchgroup=yaccSectionSep start='^%%$' end='^%%$'me=e-2,re=e-2 contains=@yaccRulesCluster nextgroup=yaccEndCode skipwhite skipempty contained
-SynFold syn region yaccEndCode matchgroup=yaccSectionSep start='^%%$' end='\%$' contains=@yaccCode contained
+SynFold syn region yaccInit start='.'ms=s-1,rs=s-1 matchgroup=yaccSectionSep end='^%%\ze\(\s*/[*/].*\)\=$'me=e-2,re=e-2 contains=@yaccInitCluster nextgroup=yaccRules skipwhite skipempty contained
+SynFold syn region yaccInit2 start='\%^.'ms=s-1,rs=s-1 matchgroup=yaccSectionSep end='^%%\ze\(\s*/[*/].*\)\=$'me=e-2,re=e-2 contains=@yaccInitCluster nextgroup=yaccRules skipwhite skipempty
+SynFold syn region yaccHeader2 matchgroup=yaccSep start="^\s*\zs%{" end="^\s*%}" contains=@yaccCode nextgroup=yaccInit skipwhite skipempty contained
+SynFold syn region yaccHeader matchgroup=yaccSep start="^\s*\zs%{" end="^\s*%}" contains=@yaccCode nextgroup=yaccInit skipwhite skipempty
+SynFold syn region yaccRules matchgroup=yaccSectionSep start='^%%\ze\(\s*/[*/].*\)\=$' end='^%%\ze\(\s*/[*/].*\)\=$'me=e-2,re=e-2 contains=@yaccRulesCluster nextgroup=yaccEndCode skipwhite skipempty contained
+SynFold syn region yaccEndCode matchgroup=yaccSectionSep start='^%%\ze\(\s*/[*/].*\)\=$' end='\%$' contains=@yaccCode contained
" ---------------------------------------------------------------------
" Yacc Commands: {{{1
@@ -72,6 +72,7 @@ syn match yaccType "<[a-zA-Z_][a-zA-Z0-9_]*>" contains=yaccBrkt contained
SynFold syn region yaccNonterminal start="^\s*\a\w*\ze\_s*\(/\*\_.\{-}\*/\)\=\_s*:" matchgroup=yaccDelim end=";" matchgroup=yaccSectionSep end='^%%$'me=e-2,re=e-2 contains=yaccAction,yaccDelim,yaccString,yaccComment contained
syn region yaccComment start="/\*" end="\*/"
+syn region yaccComment start="//" end="$"
syn match yaccString "'[^']*'" contained