# HG changeset patch # User Christian Brabandt # Date 1454017505 -3600 # Node ID ca19726d5e83c7565af7291d00806adf80924717 # Parent b2fc0ad0a69419bdd43c2f335decc3e44e7d4a7a commit https://github.com/vim/vim/commit/298b440930ecece38d6ea0505a3e582dc817e79b Author: Bram Moolenaar Date: Thu Jan 28 22:38:53 2016 +0100 Update runtime files. diff --git a/runtime/doc/netbeans.txt b/runtime/doc/netbeans.txt --- a/runtime/doc/netbeans.txt +++ b/runtime/doc/netbeans.txt @@ -1,10 +1,10 @@ -*netbeans.txt* For Vim version 7.4. Last change: 2015 Mar 14 +*netbeans.txt* For Vim version 7.4. Last change: 2016 Jan 27 VIM REFERENCE MANUAL by Gordon Prieur et al. - *socket-interface* *netbeans* *netbeans-support* + *netbeans* *netbeans-support* Vim NetBeans Protocol: a socket interface for Vim integration into an IDE. diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1,4 +1,4 @@ -*syntax.txt* For Vim version 7.4. Last change: 2016 Jan 19 +*syntax.txt* For Vim version 7.4. Last change: 2016 Jan 28 VIM REFERENCE MANUAL by Bram Moolenaar @@ -3458,7 +3458,7 @@ SYNTAX ISKEYWORD SETTING *:syn-iskeyw If no argument is given, the current value will be output. Setting this option influences what |/\k| matches in syntax patterns - and also determines where |:syn-keywords| will be checked for a new + and also determines where |:syn-keyword| will be checked for a new match. It is recommended when writing syntax files, to use this command diff --git a/runtime/doc/tags b/runtime/doc/tags --- a/runtime/doc/tags +++ b/runtime/doc/tags @@ -1179,6 +1179,7 @@ +browse various.txt /*+browse* +builtin_terms various.txt /*+builtin_terms* +byte_offset various.txt /*+byte_offset* ++channel various.txt /*+channel* +cindent various.txt /*+cindent* +clientserver various.txt /*+clientserver* +clipboard various.txt /*+clipboard* @@ -5170,6 +5171,15 @@ changelog.vim syntax.txt /*changelog.vim changenr() eval.txt /*changenr()* changetick eval.txt /*changetick* changing change.txt /*changing* +channel channel.txt /*channel* +channel-callback channel.txt /*channel-callback* +channel-commands channel.txt /*channel-commands* +channel-demo channel.txt /*channel-demo* +channel-mode channel.txt /*channel-mode* +channel-open channel.txt /*channel-open* +channel-raw channel.txt /*channel-raw* +channel-use channel.txt /*channel-use* +channel.txt channel.txt /*channel.txt* char-variable eval.txt /*char-variable* char2nr() eval.txt /*char2nr()* characterwise motion.txt /*characterwise* @@ -5301,6 +5311,7 @@ complex-repeat repeat.txt /*complex-repe compress pi_gzip.txt /*compress* conceal syntax.txt /*conceal* confirm() eval.txt /*confirm()* +connect() eval.txt /*connect()* connection-refused message.txt /*connection-refused* console-menus gui.txt /*console-menus* control intro.txt /*control* @@ -6786,6 +6797,7 @@ java-indenting indent.txt /*java-indenti java.vim syntax.txt /*java.vim* javascript-cinoptions indent.txt /*javascript-cinoptions* javascript-indenting indent.txt /*javascript-indenting* +job-control channel.txt /*job-control* join() eval.txt /*join()* jsbterm-mouse options.txt /*jsbterm-mouse* jsondecode() eval.txt /*jsondecode()* @@ -7895,6 +7907,8 @@ sed.vim syntax.txt /*sed.vim* self eval.txt /*self* send-money sponsor.txt /*send-money* send-to-menu gui_w32.txt /*send-to-menu* +sendexpr() eval.txt /*sendexpr()* +sendraw() eval.txt /*sendraw()* sendto gui_w32.txt /*sendto* sentence motion.txt /*sentence* server-functions usr_41.txt /*server-functions* @@ -7955,7 +7969,7 @@ sniff if_sniff.txt /*sniff* sniff-commands if_sniff.txt /*sniff-commands* sniff-compiling if_sniff.txt /*sniff-compiling* sniff-intro if_sniff.txt /*sniff-intro* -socket-interface netbeans.txt /*socket-interface* +socket-interface channel.txt /*socket-interface* sort() eval.txt /*sort()* sorting change.txt /*sorting* soundfold() eval.txt /*soundfold()* @@ -8507,7 +8521,6 @@ timestamps editing.txt /*timestamps* tips tips.txt /*tips* tips.txt tips.txt /*tips.txt* todo todo.txt /*todo* -todo.txt todo.txt /*todo.txt* toggle options.txt /*toggle* toggle-revins version4.txt /*toggle-revins* tolower() eval.txt /*tolower()* diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt --- a/runtime/doc/todo.txt +++ b/runtime/doc/todo.txt @@ -1,4 +1,4 @@ -*todo.txt* For Vim version 7.4. Last change: 2016 Jan 21 +todo.txt* For Vim version 7.4. Last change: 2016 Jan 27 VIM REFERENCE MANUAL by Bram Moolenaar @@ -78,9 +78,24 @@ Regexp problems: - "\%1l^#.*" does not match on a line starting with "#". The zero-width match clears the start-of-line flag. ++channel: +- cleanup on exit? in mch_getout() and getout(). +- more contents in channel.txt + C89: remove __ARGS in more places -- Script: Hirohito Higashi, Jan 21. -- Update to osdef.sh, Hirohito Higashi, 2016 Jan 21. +- /tmp/noargs.vim +- /tmp/eliminate__ARGS.vim +- Script: Hirohito Higashi, Jan 25, 2nd one. +- Assume HAVE_STDARG_H is always defined. + +This difference is unexpected: + echo v:true == 1 + 1 + echo [v:true] == [1] + 0 +It's because tv_equal() works different. + +Do we need to roll-back patch 1165, that put libintl-8.dll before libintl.dll? Need to try out instructions in INSSTALLpc.txt about how to install all interfaces and how to build Vim with them. @@ -96,9 +111,18 @@ work. (ZyX, 2013 Sep 28) With examples: Problem using ":try" inside ":execute". (ZyX, 2013 Sep 15) +jsonencode(): should convert to utf-8. (Nikolai Pavlov, 2016 Jan 23) +What if there is an invalid character? + +Should jsonencode()/jsondecode() restrict recursiveness? +Or avoid recursiveness. + Use vim.vim syntax highlighting for help file examples, but without ":" in 'iskeyword' for syntax. +Patch to make "%:h:h" return "." instead of the full path. +(Coot, 2016 Jan 24, #592) + Remove SPACE_IN_FILENAME ? What could possibly go wrong? Installation of .desktop files does not work everywhere. @@ -118,6 +142,13 @@ Win32: patch to use 64 bit stat() if pos More tests May 14. Update May 29. Update Aug 10. Now part of large file patches. (Ken Takata, 2016 Jan 19, second one) Updated patches with ordering: Jan 20. +And another update: Jan 24 + +7 Add a watchpoint in the debug mode: An expression that breaks execution + when evaluating to non-zero. Add the "watchadd expr" command, stop when + the value of the expression changes. ":watchdel" deletes an item, + ":watchlist" lists the items. (Charles Campbell) +Patch by Christian Brabandt, 2016 Jan 27. Using ":windo" to set options in all windows has the side effect that it changes the window layout and the current window. Make a variant that saves @@ -140,6 +171,8 @@ Instead of separately uploading patches github with a URL like this: https://github.com/vim/vim/compare/v7.4.920%5E...v7.4.920.diff Diff for version.c contains more context, can't skip a patch. + +Duplication of completion suggestions for ":!hom". Issue 539. > When t_Co is changed from termresponse, the OptionSet autocmmand event isn't triggered. Use the code from the end of set_num_option() in @@ -147,6 +180,13 @@ set_color_count(). Python: ":py raw_input('prompt')" doesn't work. (Manu Hack) +Comparing nested structures with "==" uses a different comperator than when +comparing individual items. +Also, "'' == 0" evaluates to true, which isn't nice. +Add "===" to have a strict comparison (type and value match). +Add "==*" (?) to have a value match, but no automatic conversion, and v:true +equals 1 and 1.0, v:false equals 0 and 0.0.? + Plugin to use Vim in MANPAGER. Konfekt, PR #491 Using uninitialized memory. (Dominique Pelle, 2015 Nov 4) @@ -171,6 +211,10 @@ Build with Python on Mac does not always (Kazunobu Kuriyama, 2015 Mar 28) Need a Vim equivalent of Python's None and a way to test for it. +Use v:none. var == v:none + +Patch to add arguments to argc() and argv(). (Yegappan Lakshmanan, 2016 Jan +24) Also need a way to get the global arg list? Update later on Jan 24 To support Thai (and other languages) word boundaries, include the ICU library: http://userguide.icu-project.org/boundaryanalysis @@ -221,7 +265,7 @@ Sep 10) Patch to be able to use hex numbers with :digraph. (Lcd, 2015 Sep 6) Update Sep 7. Update by Christian Brabandt, 2015 Sep 8. -Patch to improve I/O for Perl. (Damine, 2015 Jan 9) +Patch to improve I/O for Perl. (Damien, 2015 Jan 9, update Jan 22 2nd one) Patch to set antialiasing style on Windows. (Ondrej Balaz, 2013 Mar 14) Needs a different check for CLEARTYPE_QUALITY. @@ -258,6 +302,9 @@ same thing. Remarks on issue 543 (Rolan Patch to add grepfile(). (Scott Prager, 2015 May 26) Work in progress. +Would be useful to have a treemap() or deepmap() function. Like map() but +when an item is a list or dict would recurse into it. + Patch for global-local options consistency. (Arnaud Decara, 2015 Jul 22) Is this right? @@ -326,6 +373,8 @@ 2015 Feb 6. Wrong scrolling when using incsearch. Patch by Christian Brabandt, 2014 Dec 4. Is this a good solution? +Patch to add /pattern/ to :oldfiles. Pull #575. + Patch to allow setting w:quickfix_title via setqflist() and setloclist() functions. (Christian Brabandt, 2013 May 8, update May 21) Patch to add getlocstack() / setlocstack(). (Christian Brabandt, 2013 May 14) @@ -1115,8 +1164,6 @@ Use json format for new items in .viminf |["text","text text text" |"continuation line"] |["hist",242342342,{"arg":"value"}] - Use \" for a single ". Use \\ for a \. - See http://www.ietf.org/rfc/rfc4627.txt Writing nested List and Dict in viminfo gives error message and can't be read back. (Yukihiro Nakadaira, 2010 Nov 13) @@ -2136,28 +2183,6 @@ Add an option for a minimal text length Better plugin support (not plugin manager, see elsewhere for that): -- Add interface to another process, e.g. to run a background plugin. - Can use the code from netbeans to communicate over a socket. - A bit like +clientserver but without the hassle of starting another Vim. - Use json for the messages. - let handle = startjob({command}) # uses stdin/stdout - let handle = startjob({command}, {address}) # uses socket - let handle = connect({address}) # uses socket - let handle = deamon({command}, {address}) # start it if connect fails - let response = sendjson(handle, {json}) # sync - call sendjson(handle, {json}, {callback}) # async - call sethandler(handle, {callback}) - The response json is wrapped in an array: - [{code},{response}] - {code} must be positive, when zero the callback from sethandler() is called - The job can send Vim commands that do not require a handler: - ['ex', {Ex command}] - ['normal', {Normal mode command}] - ['keys', {condition}, {key sequence}] - ['eval', {expression}] sync, will send back result - ['expr', {expression}] async -- Native JSON support (to be able to commucate with any interface in the same - way). - Avoid use of feedkeys, add eval functions where needed: - manipulating the Visual selection? - Add createmark(): add a mark like mM, but return a unique ID. Need some way @@ -2166,6 +2191,8 @@ Better plugin support (not plugin manage - Plugins need to make a lot of effort, lots of mappings, to know what happened before pressing the key that triggers a plugin action. How about keeping the last N pressed keys, so that they do not need to be mapped? +- equivalent of netbeans_beval_cb(). With an autocommand? +- Add something to enable debugging when a remote message is received. More patches: @@ -5242,13 +5269,8 @@ 8 Should be able to yank and delete in Debug mode: -7 Add something to enable debugging when a remote message is received. 8 Add breakpoints for setting an option 8 Add breakpoints for assigning to a variable. -7 Add a watchpoint in the debug mode: An expression that breaks execution - when evaluating to non-zero. Add the "watchadd expr" command, stop when - the value of the expression changes. ":watchdel" deletes an item, - ":watchlist" lists the items. (Charles Campbell) 7 Store the history from debug mode in viminfo. 7 Make the debug mode history available with histget() et al. diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt --- a/runtime/doc/usr_41.txt +++ b/runtime/doc/usr_41.txt @@ -1,4 +1,4 @@ -*usr_41.txt* For Vim version 7.4. Last change: 2015 Nov 30 +*usr_41.txt* For Vim version 7.4. Last change: 2016 Jan 28 VIM USER MANUAL - by Bram Moolenaar @@ -893,6 +893,14 @@ Testing: *test-functions* assert_false() assert that an expression is false assert_true() assert that an expression is true +Inter-process communication: + connect() open a channel + disconnect() close a channel + sendexpr() send a JSON message over a channel + sendraw() send a raw message over a channel + jsonencode() encode an expression to a JSON string + jsondecode() decode a JSON string to Vim types + Various: *various-functions* mode() get current editing mode visualmode() last visual mode used diff --git a/runtime/doc/various.txt b/runtime/doc/various.txt --- a/runtime/doc/various.txt +++ b/runtime/doc/various.txt @@ -1,4 +1,4 @@ -*various.txt* For Vim version 7.4. Last change: 2016 Jan 10 +*various.txt* For Vim version 7.4. Last change: 2016 Jan 27 VIM REFERENCE MANUAL by Bram Moolenaar @@ -319,6 +319,7 @@ N *+builtin_terms* some terminals built B *++builtin_terms* maximal terminals builtin |builtin-terms| N *+byte_offset* support for 'o' flag in 'statusline' option, "go" and ":goto" commands. +m *+channel* inter process communication |channel| N *+cindent* |'cindent'|, C indenting N *+clientserver* Unix and Win32: Remote invocation |clientserver| *+clipboard* |clipboard| support diff --git a/runtime/indent/fortran.vim b/runtime/indent/fortran.vim --- a/runtime/indent/fortran.vim +++ b/runtime/indent/fortran.vim @@ -1,11 +1,11 @@ " Vim indent file " Language: Fortran 2008 (and older: Fortran 2003, 95, 90, and 77) -" Version: 0.42 -" Last Change: 2015 Nov. 30 +" Version: 0.44 +" Last Change: 2016 Jan. 26 " Maintainer: Ajit J. Thakkar ; " Usage: For instructions, do :help fortran-indent from Vim " Credits: -" Useful suggestions were made by: Albert Oliver Serra. +" Useful suggestions were made by: Albert Oliver Serra and Takuya Fujiwara. " Only load this indent file when no other was loaded. if exists("b:did_indent") @@ -92,10 +92,10 @@ function FortranGetIndent(lnum) "Indent do loops only if they are all guaranteed to be of do/end do type if exists("b:fortran_do_enddo") || exists("g:fortran_do_enddo") if prevstat =~? '^\s*\(\d\+\s\)\=\s*\(\a\w*\s*:\)\=\s*do\>' - let ind = ind + &sw + let ind = ind + shiftwidth() endif if getline(v:lnum) =~? '^\s*\(\d\+\s\)\=\s*end\s*do\>' - let ind = ind - &sw + let ind = ind - shiftwidth() endif endif @@ -105,14 +105,14 @@ function FortranGetIndent(lnum) \ ||prevstat=~? '^\s*\(type\|interface\|associate\|enum\)\>' \ ||prevstat=~?'^\s*\(\d\+\s\)\=\s*\(\a\w*\s*:\)\=\s*\(forall\|where\|block\)\>' \ ||prevstat=~? '^\s*\(\d\+\s\)\=\s*\(\a\w*\s*:\)\=\s*if\>' - let ind = ind + &sw + let ind = ind + shiftwidth() " Remove unwanted indent after logical and arithmetic ifs if prevstat =~? '\' && prevstat !~? '\' - let ind = ind - &sw + let ind = ind - shiftwidth() endif " Remove unwanted indent after type( statements if prevstat =~? '^\s*type\s*(' - let ind = ind - &sw + let ind = ind - shiftwidth() endif endif @@ -125,12 +125,12 @@ function FortranGetIndent(lnum) \ ||prevstat =~? '^\s*'.prefix.'subroutine\>' \ ||prevstat =~? '^\s*'.prefix.type.'function\>' \ ||prevstat =~? '^\s*'.type.prefix.'function\>' - let ind = ind + &sw + let ind = ind + shiftwidth() endif if getline(v:lnum) =~? '^\s*contains\>' \ ||getline(v:lnum)=~? '^\s*end\s*' \ .'\(function\|subroutine\|module\|program\)\>' - let ind = ind - &sw + let ind = ind - shiftwidth() endif endif @@ -141,23 +141,23 @@ function FortranGetIndent(lnum) \. '\(else\|else\s*if\|else\s*where\|case\|' \. 'end\s*\(if\|where\|select\|interface\|' \. 'type\|forall\|associate\|enum\|block\)\)\>' - let ind = ind - &sw + let ind = ind - shiftwidth() " Fix indent for case statement immediately after select if prevstat =~? '\' - let ind = ind + &sw + let ind = ind + shiftwidth() endif endif "First continuation line if prevstat =~ '&\s*$' && prev2stat !~ '&\s*$' - let ind = ind + &sw + let ind = ind + shiftwidth() endif if prevstat =~ '&\s*$' && prevstat =~ '\' - let ind = ind - &sw + let ind = ind - shiftwidth() endif "Line after last continuation line if prevstat !~ '&\s*$' && prev2stat =~ '&\s*$' && prevstat !~? '\' - let ind = ind - &sw + let ind = ind - shiftwidth() endif return ind diff --git a/runtime/indent/zimbu.vim b/runtime/indent/zimbu.vim --- a/runtime/indent/zimbu.vim +++ b/runtime/indent/zimbu.vim @@ -1,7 +1,7 @@ " Vim indent file " Language: Zimbu " Maintainer: Bram Moolenaar -" Last Change: 2012 Sep 08 +" Last Change: 2016 Jan 25 " Only load this indent file when no other was loaded. if exists("b:did_indent") @@ -74,9 +74,9 @@ func GetZimbuIndent(lnum) \ . " synIDattr(synID(line('.'), col('.'), 1), 'name')" \ . " =~ '\\(Comment\\|String\\|Char\\)$'") if pp > 0 - return indent(prevLnum) + &sw + return indent(prevLnum) + shiftwidth() endif - return indent(prevLnum) + &sw * 2 + return indent(prevLnum) + shiftwidth() * 2 endif if plnumstart == p return indent(prevLnum) @@ -102,13 +102,13 @@ func GetZimbuIndent(lnum) endif if prevline =~ '^\s*\(IF\|\|ELSEIF\|ELSE\|GENERATE_IF\|\|GENERATE_ELSEIF\|GENERATE_ELSE\|WHILE\|REPEAT\|TRY\|CATCH\|FINALLY\|FOR\|DO\|SWITCH\|CASE\|DEFAULT\|FUNC\|VIRTUAL\|ABSTRACT\|DEFINE\|REPLACE\|FINAL\|PROC\|MAIN\|NEW\|ENUM\|CLASS\|INTERFACE\|BITS\|MODULE\|SHARED\)\>' - let plindent += &sw + let plindent += shiftwidth() endif if thisline =~ '^\s*\(}\|ELSEIF\>\|ELSE\>\|CATCH\|FINALLY\|GENERATE_ELSEIF\>\|GENERATE_ELSE\>\|UNTIL\>\)' - let plindent -= &sw + let plindent -= shiftwidth() endif if thisline =~ '^\s*\(CASE\>\|DEFAULT\>\)' && prevline !~ '^\s*SWITCH\>' - let plindent -= &sw + let plindent -= shiftwidth() endif " line up continued comment that started after some code