Skip to content

Commit 2a2ff9d

Browse files
committed
Merge remote-tracking branch 'vim/master'
2 parents 4dfba19 + 3a117e1 commit 2a2ff9d

14 files changed

Lines changed: 107 additions & 68 deletions

File tree

runtime/colors/README.txt

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,16 @@ this autocmd might be useful:
4141
autocmd SourcePre */colors/blue_sky.vim set background=dark
4242
Replace "blue_sky" with the name of the colorscheme.
4343

44-
In case you want to tweak a colorscheme after it was loaded, check out that
44+
In case you want to tweak a colorscheme after it was loaded, check out the
4545
ColorScheme autocmd event.
4646

47+
To customize a colorscheme use another name, e.g. "~/.vim/colors/mine.vim",
48+
and use `:runtime` to load the original colorscheme:
49+
" load the "evening" colorscheme
50+
runtime colors/evening.vim
51+
" change the color of statements
52+
hi Statement ctermfg=Blue guifg=Blue
53+
4754
To see which highlight group is used where, find the help for
4855
"highlight-groups" and "group-name".
4956

runtime/doc/channel.txt

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*channel.txt* For Vim version 8.0. Last change: 2016 Sep 29
1+
*channel.txt* For Vim version 8.0. Last change: 2016 Oct 27
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -598,9 +598,10 @@ See |job_setoptions()| and |ch_setoptions()|.
598598
*job-exit_cb*
599599
"exit_cb": handler Callback for when the job ends. The arguments are the
600600
job and the exit status.
601-
Vim checks about every 10 seconds for jobs that ended.
602-
The check also be triggered by calling |job_status()|,
603-
which may then invoke the exit_cb handler.
601+
Vim checks up to 10 times per second for jobs that
602+
ended. The check can also be triggered by calling
603+
|job_status()|, which may then invoke the exit_cb
604+
handler.
604605
Note that data can be buffered, callbacks may still be
605606
called after the process ends.
606607
*job-timeout*

runtime/doc/pi_gzip.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*pi_gzip.txt* For Vim version 8.0. Last change: 2012 Jul 19
1+
*pi_gzip.txt* For Vim version 8.0. Last change: 2016 Oct 30
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -27,6 +27,7 @@ with these extensions:
2727
*.bz2 bzip2
2828
*.lzma lzma
2929
*.xz xz
30+
*.lz lzip
3031

3132
That's actually the only thing you need to know. There are no options.
3233

runtime/doc/syntax.txt

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*syntax.txt* For Vim version 8.0. Last change: 2016 Sep 29
1+
*syntax.txt* For Vim version 8.0. Last change: 2016 Oct 30
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -4597,7 +4597,14 @@ in their own color.
45974597

45984598
Doesn't work recursively, thus you can't use
45994599
":colorscheme" in a color scheme script.
4600-
After the color scheme has been loaded the
4600+
4601+
To customize a colorscheme use another name, e.g.
4602+
"~/.vim/colors/mine.vim", and use `:runtime` to load
4603+
the original colorscheme: >
4604+
runtime colors/evening.vim
4605+
hi Statement ctermfg=Blue guifg=Blue
4606+
4607+
< After the color scheme has been loaded the
46014608
|ColorScheme| autocommand event is triggered.
46024609
For info about writing a colorscheme file: >
46034610
:edit $VIMRUNTIME/colors/README.txt

runtime/doc/todo.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ not be repeated below, unless there is extra information.
3535
-------------------- Known bugs and current work -----------------------
3636

3737
+channel:
38-
- Check for job cleanup more often? Patch from Ozaki Kiichi, 2016 Oct 22.
3938
- Problem with stderr on Windows? (Vincent Rischmann, 2016 Aug 31, #1026)
4039
- Add 'cwd' argument to start_job(): directory to change to in the child.
4140
check for valid directory before forking.
@@ -111,8 +110,6 @@ Allow using json with empty key? Dict already has it.
111110

112111
Json string with trailing \u should be an error. (Lcd)
113112

114-
Patch to fix conceal mode. (Christian Brabandt, 2016 Oct 23, close #1092)
115-
116113
Patch to reset ex_exitvalue after catch. (Christian Brabandt, 2016 Oct 23)
117114

118115
Patch to deal with changed configure events in GTK 3. (Jan Alexander Steffens,

runtime/filetype.vim

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
" Vim support file to detect file types
22
"
33
" Maintainer: Bram Moolenaar <[email protected]>
4-
" Last Change: 2016 Oct 15
4+
" Last Change: 2016 Oct 28
55

66
" Listen very carefully, I will say this only once
77
if exists("did_load_filetypes")
@@ -862,7 +862,7 @@ au BufNewFile,BufRead *.ht setf haste
862862
au BufNewFile,BufRead *.htpp setf hastepreproc
863863

864864
" Hercules
865-
au BufNewFile,BufRead *.vc,*.ev,*.rs,*.sum,*.errsum setf hercules
865+
au BufNewFile,BufRead *.vc,*.ev,*.sum,*.errsum setf hercules
866866

867867
" HEX (Intel)
868868
au BufNewFile,BufRead *.hex,*.h32 setf hex
@@ -1760,6 +1760,9 @@ au BufNewFile,BufRead *.rb,*.rbw setf ruby
17601760
" RubyGems
17611761
au BufNewFile,BufRead *.gemspec setf ruby
17621762

1763+
" Rust
1764+
au BufNewFile,BufRead *.rs setf rust
1765+
17631766
" Rackup
17641767
au BufNewFile,BufRead *.ru setf ruby
17651768

runtime/ftplugin/context.vim

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
" Language: ConTeXt typesetting engine
33
" Maintainer: Nicola Vitacolonna <[email protected]>
44
" Former Maintainers: Nikolai Weibull <[email protected]>
5-
" Latest Revision: 2016 Oct 14
5+
" Latest Revision: 2016 Oct 30
66

77
if exists("b:did_ftplugin")
88
finish
@@ -21,7 +21,7 @@ let b:undo_ftplugin = "setl com< cms< def< inc< sua< fo< ofu<"
2121

2222
setlocal comments=b:%D,b:%C,b:%M,:% commentstring=%\ %s formatoptions+=tjcroql2
2323
if get(b:, 'context_metapost', get(g:, 'context_metapost', 1))
24-
setlocal omnifunc=context#complete
24+
setlocal omnifunc=contextcomplete#Complete
2525
let g:omni_syntax_group_include_context = 'mf\w\+,mp\w\+'
2626
let g:omni_syntax_group_exclude_context = 'mfTodoComment'
2727
endif

runtime/plugin/gzip.vim

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
" Vim plugin for editing compressed files.
22
" Maintainer: Bram Moolenaar <[email protected]>
3-
" Last Change: 2010 Mar 10
3+
" Last Change: 2016 Oct 30
44

55
" Exit quickly when:
66
" - this plugin was already loaded
@@ -20,25 +20,29 @@ augroup gzip
2020
"
2121
" Set binary mode before reading the file.
2222
" Use "gzip -d", gunzip isn't always available.
23-
autocmd BufReadPre,FileReadPre *.gz,*.bz2,*.Z,*.lzma,*.xz setlocal bin
23+
autocmd BufReadPre,FileReadPre *.gz,*.bz2,*.Z,*.lzma,*.xz,*.lz setlocal bin
2424
autocmd BufReadPost,FileReadPost *.gz call gzip#read("gzip -dn")
2525
autocmd BufReadPost,FileReadPost *.bz2 call gzip#read("bzip2 -d")
2626
autocmd BufReadPost,FileReadPost *.Z call gzip#read("uncompress")
2727
autocmd BufReadPost,FileReadPost *.lzma call gzip#read("lzma -d")
2828
autocmd BufReadPost,FileReadPost *.xz call gzip#read("xz -d")
29+
autocmd BufReadPost,FileReadPost *.lz call gzip#read("lzip -d")
2930
autocmd BufWritePost,FileWritePost *.gz call gzip#write("gzip")
3031
autocmd BufWritePost,FileWritePost *.bz2 call gzip#write("bzip2")
3132
autocmd BufWritePost,FileWritePost *.Z call gzip#write("compress -f")
3233
autocmd BufWritePost,FileWritePost *.lzma call gzip#write("lzma -z")
3334
autocmd BufWritePost,FileWritePost *.xz call gzip#write("xz -z")
35+
autocmd BufWritePost,FileWritePost *.lz call gzip#write("lzip")
3436
autocmd FileAppendPre *.gz call gzip#appre("gzip -dn")
3537
autocmd FileAppendPre *.bz2 call gzip#appre("bzip2 -d")
3638
autocmd FileAppendPre *.Z call gzip#appre("uncompress")
3739
autocmd FileAppendPre *.lzma call gzip#appre("lzma -d")
3840
autocmd FileAppendPre *.xz call gzip#appre("xz -d")
41+
autocmd FileAppendPre *.lz call gzip#appre("lzip -d")
3942
autocmd FileAppendPost *.gz call gzip#write("gzip")
4043
autocmd FileAppendPost *.bz2 call gzip#write("bzip2")
4144
autocmd FileAppendPost *.Z call gzip#write("compress -f")
4245
autocmd FileAppendPost *.lzma call gzip#write("lzma -z")
4346
autocmd FileAppendPost *.xz call gzip#write("xz -z")
47+
autocmd FileAppendPost *.lz call gzip#write("lzip")
4448
augroup END

runtime/syntax/cpp.vim

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
" Language: C++
33
" Current Maintainer: vim-jp (https://github.com/vim-jp/vim-cpp)
44
" Previous Maintainer: Ken Shan <[email protected]>
5-
" Last Change: 2016 Jul 07
5+
" Last Change: 2016 Oct 28
66

77
" quit when a syntax file was already loaded
88
if exists("b:current_syntax")
@@ -31,7 +31,7 @@ syn keyword cppConstant __cplusplus
3131
" C++ 11 extensions
3232
if !exists("cpp_no_cpp11")
3333
syn keyword cppModifier override final
34-
syn keyword cppType nullptr_t
34+
syn keyword cppType nullptr_t auto
3535
syn keyword cppExceptions noexcept
3636
syn keyword cppStorageClass constexpr decltype thread_local
3737
syn keyword cppConstant nullptr
@@ -46,7 +46,11 @@ endif
4646

4747
" C++ 14 extensions
4848
if !exists("cpp_no_cpp14")
49-
syn match cppNumber display "\<0b[01]\+\(u\=l\{0,2}\|ll\=u\)\>"
49+
syn case ignore
50+
syn match cppNumber display "\<0b[01]\('\=[01]\+\)*\(u\=l\{0,2}\|ll\=u\)\>"
51+
syn match cppNumber display "\<[1-9]\('\=\d\+\)*\(u\=l\{0,2}\|ll\=u\)\>"
52+
syn match cppNumber display "\<0x\x\('\=\x\+\)*\(u\=l\{0,2}\|ll\=u\)\>"
53+
syn case match
5054
endif
5155

5256
" The minimum and maximum operators in GNU C++

runtime/syntax/python.vim

Lines changed: 52 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
" Vim syntax file
22
" Language: Python
33
" Maintainer: Zvezdan Petkovic <[email protected]>
4-
" Last Change: 2016 Sep 14
4+
" Last Change: 2016 Oct 29
55
" Credits: Neil Schemenauer <[email protected]>
66
" Dmitry Vasiliev
77
"
@@ -46,6 +46,29 @@ endif
4646
let s:cpo_save = &cpo
4747
set cpo&vim
4848

49+
if exists("python_no_doctest_highlight")
50+
let python_no_doctest_code_highlight = 1
51+
endif
52+
53+
if exists("python_highlight_all")
54+
if exists("python_no_builtin_highlight")
55+
unlet python_no_builtin_highlight
56+
endif
57+
if exists("python_no_doctest_code_highlight")
58+
unlet python_no_doctest_code_highlight
59+
endif
60+
if exists("python_no_doctest_highlight")
61+
unlet python_no_doctest_highlight
62+
endif
63+
if exists("python_no_exception_highlight")
64+
unlet python_no_exception_highlight
65+
endif
66+
if exists("python_no_number_highlight")
67+
unlet python_no_number_highlight
68+
endif
69+
let python_space_error_highlight = 1
70+
endif
71+
4972
" Keep Python keywords in alphabetical order inside groups for easy
5073
" comparison with the table in the 'Python Language Reference'
5174
" https://docs.python.org/2/reference/lexical_analysis.html#keywords,
@@ -81,30 +104,31 @@ syn keyword pythonInclude from import
81104
syn keyword pythonAsync async await
82105

83106
" Decorators (new in Python 2.4)
84-
" Python 3.5 introduced the use of the same symbol for matrix
85-
" multiplication. We now have to exclude the symbol from being
86-
" highlighted when used in that context. Hence, the check that it's
87-
" preceded by empty space only (possibly in a docstring/doctest) and
88-
" followed by decorator name, optional parenthesized list of arguments,
89-
" and the next line with either def, class, or another decorator.
90-
syn match pythonDecorator
91-
\ "\%(\%(^\s*\)\%(\%(>>>\|\.\.\.\)\s\+\)\=\)\zs@\%(\s*\h\%(\w\|\.\)*\s*\%((\_\s\{-}[^)]\_.\{-})\s*\)\=\%(#.*\)\=\n\s*\%(\.\.\.\s\+\)\=\%(@\s*\h\|\%(def\|class\)\s\+\)\)\@="
92-
\ display nextgroup=pythonDecoratorName skipwhite
93-
94107
" A dot must be allowed because of @MyClass.myfunc decorators.
95-
" It must be preceded by a decorator symbol and on a separate line from
96-
" a function/class it decorates.
97-
syn match pythonDecoratorName
98-
\ "\%(@\s*\)\@<=\h\%(\w\|\.\)*\%(\s*\%((\_\s\{-}[^)]\_.\{-})\s*\)\=\%(#.*\)\=\n\)\@="
99-
\ contained display nextgroup=pythonFunction skipnl
108+
syn match pythonDecorator "@" display contained
109+
syn match pythonDecoratorName "@\s*\h\%(\w\|\.\)*" display contains=pythonDecorator
110+
111+
" Python 3.5 introduced the use of the same symbol for matrix multiplication:
112+
" https://www.python.org/dev/peps/pep-0465/. We now have to exclude the
113+
" symbol from highlighting when used in that context.
114+
" Single line multiplication.
115+
syn match pythonMatrixMultiply
116+
\ "\%(\w\|[])]\)\s*@"
117+
\ contains=ALLBUT,pythonDecoratorName,pythonDecorator,pythonFunction,pythonDoctestValue
118+
\ transparent
119+
" Multiplication continued on the next line after backslash.
120+
syn match pythonMatrixMultiply
121+
\ "[^\\]\\\s*\n\%(\s*\.\.\.\s\)\=\s\+@"
122+
\ contains=ALLBUT,pythonDecoratorName,pythonDecorator,pythonFunction,pythonDoctestValue
123+
\ transparent
124+
" Multiplication in a parenthesized expression over multiple lines with @ at
125+
" the start of each continued line; very similar to decorators and complex.
126+
syn match pythonMatrixMultiply
127+
\ "^\s*\%(\%(>>>\|\.\.\.\)\s\+\)\=\zs\%(\h\|\%(\h\|[[(]\).\{-}\%(\w\|[])]\)\)\s*\n\%(\s*\.\.\.\s\)\=\s\+@\%(.\{-}\n\%(\s*\.\.\.\s\)\=\s\+@\)*"
128+
\ contains=ALLBUT,pythonDecoratorName,pythonDecorator,pythonFunction,pythonDoctestValue
129+
\ transparent
100130

101-
" The zero-length non-grouping match of def or class before the function
102-
" name is extremely important in pythonFunction. Without it, everything
103-
" is interpreted as a function inside the contained environment of
104-
" doctests.
105-
syn match pythonFunction
106-
\ "\%(\%(^\s*\)\%(\%(>>>\|\.\.\.\)\s\+\)\=\%(def\|class\)\s\+\)\@<=\h\w*"
107-
\ contained
131+
syn match pythonFunction "\h\w*" display contained
108132

109133
syn match pythonComment "#.*$" contains=pythonTodo,@Spell
110134
syn keyword pythonTodo FIXME NOTE NOTES TODO XXX contained
@@ -131,25 +155,6 @@ syn match pythonEscape "\%(\\u\x\{4}\|\\U\x\{8}\)" contained
131155
syn match pythonEscape "\\N{\a\+\%(\s\a\+\)*}" contained
132156
syn match pythonEscape "\\$"
133157

134-
if exists("python_highlight_all")
135-
if exists("python_no_builtin_highlight")
136-
unlet python_no_builtin_highlight
137-
endif
138-
if exists("python_no_doctest_code_highlight")
139-
unlet python_no_doctest_code_highlight
140-
endif
141-
if exists("python_no_doctest_highlight")
142-
unlet python_no_doctest_highlight
143-
endif
144-
if exists("python_no_exception_highlight")
145-
unlet python_no_exception_highlight
146-
endif
147-
if exists("python_no_number_highlight")
148-
unlet python_no_number_highlight
149-
endif
150-
let python_space_error_highlight = 1
151-
endif
152-
153158
" It is very important to understand all details before changing the
154159
" regular expressions below or their order.
155160
" The word boundaries are *not* the floating-point number boundaries
@@ -213,7 +218,9 @@ if !exists("python_no_builtin_highlight")
213218
" non-essential built-in functions; Python 2 only
214219
syn keyword pythonBuiltin apply buffer coerce intern
215220
" avoid highlighting attributes as builtins
216-
syn match pythonAttribute /\.\h\w*/hs=s+1 contains=ALLBUT,pythonBuiltin transparent
221+
syn match pythonAttribute /\.\h\w*/hs=s+1
222+
\ contains=ALLBUT,pythonBuiltin,pythonFunction,pythonAsync
223+
\ transparent
217224
endif
218225

219226
" From the 'Python Library Reference' class hierarchy at the bottom.
@@ -275,7 +282,7 @@ if !exists("python_no_doctest_highlight")
275282
if !exists("python_no_doctest_code_highlight")
276283
syn region pythonDoctest
277284
\ start="^\s*>>>\s" end="^\s*$"
278-
\ contained contains=ALLBUT,pythonDoctest,@Spell
285+
\ contained contains=ALLBUT,pythonDoctest,pythonFunction,@Spell
279286
syn region pythonDoctestValue
280287
\ start=+^\s*\%(>>>\s\|\.\.\.\s\|"""\|'''\)\@!\S\++ end="$"
281288
\ contained
@@ -287,7 +294,7 @@ if !exists("python_no_doctest_highlight")
287294
endif
288295

289296
" Sync at the beginning of class, function, or method definition.
290-
syn sync match pythonSync grouphere NONE "^\s*\%(def\|class\)\s\+\h\w*\s*("
297+
syn sync match pythonSync grouphere NONE "^\%(def\|class\)\s\+\h\w*\s*[(:]"
291298

292299
" The default highlight links. Can be overridden later.
293300
hi def link pythonStatement Statement

0 commit comments

Comments
 (0)