]> granicus.if.org Git - vim/commitdiff
Update runtime files.
authorBram Moolenaar <Bram@vim.org>
Tue, 13 Jun 2017 16:12:01 +0000 (18:12 +0200)
committerBram Moolenaar <Bram@vim.org>
Tue, 13 Jun 2017 16:12:01 +0000 (18:12 +0200)
Includes changing &sw to shiftwidth() for all indent scripts.

65 files changed:
runtime/doc/channel.txt
runtime/doc/eval.txt
runtime/doc/pattern.txt
runtime/doc/tags
runtime/doc/todo.txt
runtime/filetype.vim
runtime/indent/ada.vim
runtime/indent/awk.vim
runtime/indent/bst.vim
runtime/indent/bzl.vim
runtime/indent/cdl.vim
runtime/indent/chaiscript.vim
runtime/indent/clojure.vim
runtime/indent/cmake.vim
runtime/indent/cobol.vim
runtime/indent/cucumber.vim
runtime/indent/dylan.vim
runtime/indent/erlang.vim
runtime/indent/eruby.vim
runtime/indent/falcon.vim
runtime/indent/gitconfig.vim
runtime/indent/gitolite.vim
runtime/indent/go.vim
runtime/indent/haml.vim
runtime/indent/hamster.vim
runtime/indent/hog.vim
runtime/indent/html.vim
runtime/indent/idlang.vim
runtime/indent/ishd.vim
runtime/indent/javascript.vim
runtime/indent/json.vim
runtime/indent/liquid.vim
runtime/indent/logtalk.vim
runtime/indent/lua.vim
runtime/indent/matlab.vim
runtime/indent/mma.vim
runtime/indent/ocaml.vim
runtime/indent/occam.vim
runtime/indent/pascal.vim
runtime/indent/perl.vim
runtime/indent/perl6.vim
runtime/indent/php.vim
runtime/indent/postscr.vim
runtime/indent/pov.vim
runtime/indent/prolog.vim
runtime/indent/rpl.vim
runtime/indent/ruby.vim
runtime/indent/rust.vim
runtime/indent/sass.vim
runtime/indent/sdl.vim
runtime/indent/sml.vim
runtime/indent/sqlanywhere.vim
runtime/indent/systemverilog.vim
runtime/indent/teraterm.vim
runtime/indent/tex.vim
runtime/indent/tilde.vim
runtime/indent/vb.vim
runtime/indent/vhdl.vim
runtime/indent/xml.vim
runtime/indent/yaml.vim
runtime/syntax/debchangelog.vim
runtime/syntax/debsources.vim
runtime/syntax/help.vim
runtime/syntax/php.vim
src/po/it.po

index 3078d31acb47da4c5d2477d04aa270ff4a70546a..39cd912ad564c7491b21b1c53752d3a82b625653 100644 (file)
@@ -1,4 +1,4 @@
-*channel.txt*      For Vim version 8.0.  Last change: 2016 Dec 02
+*channel.txt*      For Vim version 8.0.  Last change: 2017 Jun 11
 
 
                  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -489,6 +489,11 @@ If you want to handle both stderr and stdout with one handler use the
 "callback" option: >
     let job = job_start(command, {"callback": "MyHandler"}) 
 
+Depending on the system, starting a job can put Vim in the background, the
+started job gets the focus.  To avoid that, use the `foreground()` function.
+This might not always work when called early, put in the callback handler or
+use a timer to call it after the job has started.
+
 You can send a message to the command with ch_evalraw().  If the channel is in
 JSON or JS mode you can use ch_evalexpr().
 
index 701fd398535e567d169a8dddde96c1d83aa49712..dec960bb789f7101b7f96ed83e95be2ba0877ac4 100644 (file)
@@ -1,4 +1,4 @@
-*eval.txt*     For Vim version 8.0.  Last change: 2017 Jun 05
+*eval.txt*     For Vim version 8.0.  Last change: 2017 Jun 13
 
 
                  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -5465,7 +5465,10 @@ line({expr})     The result is a Number, which is the line number of the file
 <                                                      *last-position-jump*
                This autocommand jumps to the last known position in a file
                just after opening it, if the '" mark is set: >
-       :au BufReadPost * if line("'\"") > 1 && line("'\"") <= line("$") | exe "normal! g`\"" | endif
+     :au BufReadPost *
+         \ if line("'\"") > 1 && line("'\"") <= line("$") && &ft !~# 'commit' 
+         \ |   exe "normal! g`\""
+         \ | endif
 
 line2byte({lnum})                                      *line2byte()*
                Return the byte count from the start of the buffer for line
index d6764096a7454d29d3392152e0e61e1d73e83546..89b24c6477c0dbc70f7dc21b07f43d0c549fb65e 100644 (file)
@@ -1,4 +1,4 @@
-*pattern.txt*   For Vim version 8.0.  Last change: 2017 Mar 29
+*pattern.txt*   For Vim version 8.0.  Last change: 2017 Jun 05
 
 
                  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -1076,12 +1076,16 @@ x       A single character, with no special meaning, matches itself
        ":s/[/x/" searches for "[/x" and replaces it with nothing.  It does
        not search for "[" and replaces it with "x"!
 
+                                                               *E944* *E945*
        If the sequence begins with "^", it matches any single character NOT
        in the collection: "[^xyz]" matches anything but 'x', 'y' and 'z'.
        - If two characters in the sequence are separated by '-', this is
          shorthand for the full list of ASCII characters between them.  E.g.,
-         "[0-9]" matches any decimal digit.  Non-ASCII characters can be
-         used, but the character values must not be more than 256 apart.
+         "[0-9]" matches any decimal digit. If the starting character exceeds
+         the ending character, e.g. [c-a], E944 occurs. Non-ASCII characters
+         can be used, but the character values must not be more than 256 apart
+         in the old regexp engine. For example, searching by [\u3000-\u4000]
+         after setting re=1 emits a E945 error. Prepending \%#=2 will fix it.
        - A character class expression is evaluated to the set of characters
          belonging to that character class.  The following character classes
          are supported:
index af843e3135d35552868b29421b96863fa583c793..224007c7ca921ac79916c245a5a1b143c199de23 100644 (file)
@@ -4519,6 +4519,8 @@ E940      eval.txt        /*E940*
 E941   eval.txt        /*E941*
 E942   eval.txt        /*E942*
 E943   message.txt     /*E943*
+E944   pattern.txt     /*E944*
+E945   pattern.txt     /*E945*
 E95    message.txt     /*E95*
 E96    diff.txt        /*E96*
 E97    diff.txt        /*E97*
index ac8026ba832a6cf1301367d804ffa78ac26784b9..c833312201d61effe0d61a72017be815c858ff9e 100644 (file)
@@ -1,4 +1,4 @@
-*todo.txt*      For Vim version 8.0.  Last change: 2017 Jun 05
+*todo.txt*      For Vim version 8.0.  Last change: 2017 Jun 13
 
 
                  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -113,6 +113,7 @@ With foldmethod=syntax and nofoldenable comment highlighting isn't removed.
 (Marcin Szewczyk, 2017 Apr 26)
 
 ml_get error when using a Python. (Yggdroot, 2017 Jun 1, #1737)
+Lemonboy can reproduce (2017 Jun 5)
 
 ml_get errors with buggy script. (Dominique, 2017 Apr 30)
 
@@ -144,15 +145,9 @@ Openhab syntax file (mueller, #1678)
 
 Use gvimext.dll from the nightly build? (Issue #249)
 
-Patch to remove HAVE_GTK_MULTIHEAD-relevant code. (Kazunobu Kuriyama, 2017 May
-5) Update May 11
-
 'synmaxcol' works with bytes instead of screen cells. (Llandon, 2017 May 31,
 #1736)
 
-Patch to pass quickfix list index to functions. (Yegappan Lakshmanan, 2017 May
-31)
-
 Problem with using :cd when remotely editing a file. (Gerd Wachsmuth, 2017 May
 8, #1690)
 
@@ -168,16 +163,6 @@ manager.  Problem with Motif?
 Bogus characters inserted when triggering indent while changing text.
 (Vitor Antunes, 2016 Nov 22, #1269)
 
-Patch to have ":stag" respect 'switchbuf'. (Ingo Karkat, 2017 May 5, #1681)
-
-Patch to improve building with MSVC. (Leonardo Manera, #1747)
-
-Wrong selection of quoted text (Guraga, #1687)
-Patch to fix selection of quoted text. (Christian Brabandt, 2017 May 7, #1687)
-
-Patch to use separate error message for regex range. (Itchyny, Ken Hamada,
-2017 May 16)
-
 Segmentation fault with complete(). (Lifepillar, 2017 Apr 29, #1668)
 Check for "pat" to be NULL in search_for_exact_line()?
 How did it get NULL?  Comment by Christian, Apr 30.
@@ -185,18 +170,8 @@ How did it get NULL?  Comment by Christian, Apr 30.
 Is it possible to keep the complete menu open when calling complete()?
 (Prabir Shrestha, 2017 May 19, #1713)
 
-Calling may_req_ambiguous_char_width() and may_req_bg_color() only after
-executing command line commands may not work properly.
-(Rastislav Barlink, 2017 May 18)
-Set "starting" to 0 earlier, and move the may_req calls above exe_commands()?
-No, that's a problem with using "-c quit", not running Vim interactive.
-
 Memory leak in test97?  The string is actually freed.  Weird.
 
-Patch for shellescape(). (Christian Brabandt, 2017 Apr 20, #1590)
-
-Patch for flickering redraw. (Hirohito Higashi, 2017 Apr 23, #1637)
-
 New value "uselast" for 'switchbuf'. (Lemonboy, 2017 Apr 23, #1652)
 
 Add a toolbar in the terminal.  Can be global, above all windows, or specific
@@ -212,18 +187,6 @@ Perhaps simpler: actually delete the mappings.  Use maplist() to list matching
 mappings (with a lhs prefix, like maparg()), mapdelete() to delete,
 maprestore() to restore (using the output of maplist().
 
-Patch to support chinese wordcount in utf-8. (Rain, 2017 May 24, #1722)
-Or not?
-
-"gn" selects one character instead of the searched text. (keyboardfire, #1683)
-Patch by Christian, 2017 May 7.
-
-Wrong memory access using p_fdm, found in patch to add tests for diff mode
-(#1658) (Dominique Pelle, 2017 May 6)
-
-Patch to improve test coverage for diff mode. (Dominique Pelle, 2017 May 11,
-#1685)
-
 Add an argument to :mkvimrc (or add aother command) to skip mappings from
 plugins (source is a Vim script).  No need to put these in a .vimrc, they will
 be defined when the plugin is loaded.
@@ -249,6 +212,7 @@ Also get E749 on exit.
 Another example in #1309
 
 Patch to change all use of &sw to shiftwidth(). (Tyru, 2017 Feb 19)
+Takuya Fujiwara
 Wait until maintainers integrate it.
 
 When deleting a mark or register, leave a tombstone, so that it's also deleted
@@ -358,6 +322,8 @@ Patch for wrong cursor position on wrapped line, involving breakindent.
 (Ozaki Kiichi, 2016 Nov 25)
 Does this also fix #1408 ?
 
+Patch to add "module" to quickfix entries. (Coot, 2017 Jun 8, #1757)
+
 Patch for 'cursorlinenr' option. (Ozaki Kiichi, 2016 Nov 30)
 
 When 'completeopt' has "noselect" does not insert a newline. (Lifepillar, 2017
@@ -500,9 +466,6 @@ This does not work: :set cscopequickfix=a-
 
 Possibly wrong value for seq_cur. (Florent Fayolle, 2016 May 15, #806)
 
-Patch to add separate highlighting for quickfix current line.
-(anishsane, 2016 Sep 16, #1080)
-
 Filetype plugin for awk. (Doug Kearns, 2016 Sep 5)
 
 Patch to improve map documentation. Issue #799.
@@ -539,6 +502,9 @@ Because of using the initial buffer? (Dun Peal, 2016 May 12)
 Patch to add the :bvimgrep command.  (Christian Brabandt, 2014 Nov 12)
 Updated 2016 Jun 10, #858  Update 2017 Mar 28: use <buffer>
 
+Patch to fix that an encoding conversion failure results in a corrupted or
+empty file. (Christian Brabandt, #1765, https://github.com/chrisbra/vim-mq-patches/blob/master/conversion_error)
+
 Add redrawtabline command. (Naruhiko Nishino, 2016 Jun 11)
 
 Neovim patch for utfc_ptr2char_len() https://github.com/neovim/neovim/pull/4574
@@ -1032,8 +998,6 @@ Patch to handle integer overflow. (Aaron Burrow, 2013 Dec 12)
 Patch to add "ntab" item in 'listchars' to repeat first character. (Nathaniel
 Braun, pragm, 2013 Oct 13)  A better solution 2014 Mar 5.
 
-/[b-a] gives error E16, should probably be E769.
-
 7   Windows XP: When using "ClearType" for text smoothing, a column of yellow
     pixels remains when typing spaces in front of a "D" ('guifont' set to
     "lucida_console:h8").
index 9878236b62da6a7ea9bd7afd79648e81c41c77ec..635e1c3ce7b092e3aa536b19684d3af56debcef3 100644 (file)
@@ -1,7 +1,7 @@
 " Vim support file to detect file types
 "
 " Maintainer:  Bram Moolenaar <Bram@vim.org>
-" Last Change: 2017 Jun 04
+" Last Change: 2017 Jun 12
 
 " Listen very carefully, I will say this only once
 if exists("did_load_filetypes")
@@ -2253,6 +2253,8 @@ func! s:FTtex()
     let format = tolower(matchstr(firstline, '\a\+'))
     let format = substitute(format, 'pdf', '', '')
     if format == 'tex'
+      let format = 'latex'
+    elseif format == 'plaintex'
       let format = 'plain'
     endif
   else
index 5019f0b736e9aea1598387e58c89d076b689b438..1ca7fbacbe274ab6ff2e0035afb1be2090981612 100644 (file)
@@ -87,7 +87,7 @@ function s:MainBlockIndent (prev_indent, prev_lnum, blockstart, stop_at)
       endwhile
    endwhile
    " Fallback - just move back one
-   return a:prev_indent - &sw
+   return a:prev_indent - shiftwidth()
 endfunction MainBlockIndent
 
 " Section: s:EndBlockIndent {{{1
@@ -131,7 +131,7 @@ function s:EndBlockIndent( prev_indent, prev_lnum, blockstart, blockend )
       endwhile
    endwhile
    " Fallback - just move back one
-   return a:prev_indent - &sw
+   return a:prev_indent - shiftwidth()
 endfunction EndBlockIndent
 
 " Section: s:StatementIndent {{{1
@@ -213,15 +213,15 @@ function GetAdaIndent()
       endif
       " Move indent in
       if ! false_match
-        let ind = ind + &sw
+        let ind = ind + shiftwidth()
       endif
    elseif line =~ '^\s*\(case\|exception\)\>'
       " Move indent in twice (next 'when' will move back)
-      let ind = ind + 2 * &sw
+      let ind = ind + 2 * shiftwidth()
    elseif line =~ '^\s*end\s*record\>'
       " Move indent back to tallying 'type' preceeding the 'record'.
       " Allow indent to be equal to 'end record's.
-      let ind = s:MainBlockIndent( ind+&sw, lnum, 'type\>', '' )
+      let ind = s:MainBlockIndent( ind+shiftwidth(), lnum, 'type\>', '' )
    elseif line =~ '\(^\s*new\>.*\)\@<!)\s*[;,]\s*$'
       " Revert to indent of line that started this parenthesis pair
       exe lnum
@@ -235,10 +235,10 @@ function GetAdaIndent()
       exe v:lnum
    elseif line =~ '[.=(]\s*$'
       " A statement continuation - move in one
-      let ind = ind + &sw
+      let ind = ind + shiftwidth()
    elseif line =~ '^\s*new\>'
       " Multiple line generic instantiation ('package blah is\nnew thingy')
-      let ind = s:StatementIndent( ind - &sw, lnum )
+      let ind = s:StatementIndent( ind - shiftwidth(), lnum )
    elseif line =~ ';\s*$'
       " Statement end (but not 'end' ) - try to find current statement-start indent
       let ind = s:StatementIndent( ind, lnum )
@@ -256,17 +256,17 @@ function GetAdaIndent()
    elseif continuation && line =~ '^\s*('
       " Don't do this if we've already indented due to the previous line
       if ind == initind
-        let ind = ind + &sw
+        let ind = ind + shiftwidth()
       endif
    elseif line =~ '^\s*\(begin\|is\)\>'
       let ind = s:MainBlockIndent( ind, lnum, '\(procedure\|function\|declare\|package\|task\)\>', 'begin\>' )
    elseif line =~ '^\s*record\>'
-      let ind = s:MainBlockIndent( ind, lnum, 'type\>\|for\>.*\<use\>', '' ) + &sw
+      let ind = s:MainBlockIndent( ind, lnum, 'type\>\|for\>.*\<use\>', '' ) + shiftwidth()
    elseif line =~ '^\s*\(else\|elsif\)\>'
       let ind = s:MainBlockIndent( ind, lnum, 'if\>', '' )
    elseif line =~ '^\s*when\>'
       " Align 'when' one /in/ from matching block start
-      let ind = s:MainBlockIndent( ind, lnum, '\(case\|exception\)\>', '' ) + &sw
+      let ind = s:MainBlockIndent( ind, lnum, '\(case\|exception\)\>', '' ) + shiftwidth()
    elseif line =~ '^\s*end\>\s*\<if\>'
       " End of if statements
       let ind = s:EndBlockIndent( ind, lnum, 'if\>', 'end\>\s*\<if\>' )
index 6f6b70cc4e5a22ed9cdb5cf0d6729a26568196b9..aad73ee71fecebc68ca534d1f3c3f457d988a1d2 100644 (file)
@@ -60,7 +60,7 @@ function! GetAwkIndent()
    " 'pattern { action }' (simple check match on /{/ increases the indent then)
 
    if s:Get_brace_balance( prev_data, '{', '}' ) > 0
-      return ind + &sw
+      return ind + shiftwidth()
    endif
 
    let brace_balance = s:Get_brace_balance( prev_data, '(', ')' )
@@ -99,7 +99,7 @@ function! GetAwkIndent()
          return s:Safe_indent( ind, s:First_word_len(prev_data), getline(v:lnum))
        else
         " if/for/while without '{'
-        return ind + &sw
+        return ind + shiftwidth()
        endif
      endif
    endif
@@ -140,7 +140,7 @@ function! GetAwkIndent()
 
    " Decrease indent if this line contains a '}'.
    if getline(v:lnum) =~ '^\s*}'
-      let ind = ind - &sw
+      let ind = ind - shiftwidth()
    endif
 
    return ind
index be1f63e8e98da8996865beffc67c9e22009812f6..47e3058810390797615e9678e4707adfa140efa6 100644 (file)
@@ -69,7 +69,7 @@ function! GetBstIndent(lnum) abort
     endif
     let fakeline = substitute(line,'^}','','').matchstr(cline,'^}')
     let ind = indent(lnum)
-    let ind = ind + &sw * s:count(line,'{')
-    let ind = ind - &sw * s:count(fakeline,'}')
+    let ind = ind + shiftwidth() * s:count(line,'{')
+    let ind = ind - shiftwidth() * s:count(fakeline,'}')
     return ind
 endfunction
index 24e5b870cdc2ccb0b3537cc91e207a296b5f4231..6904bfdedb34d3490f8b41f82e00fa24f3a13ba9 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:    Bazel (http://bazel.io)
 " Maintainer:  David Barnett (https://github.com/google/vim-ft-bzl)
-" Last Change: 2015 Aug 11
+" Last Change: 2017 Jun 13
 
 if exists('b:did_indent')
   finish
@@ -41,11 +41,8 @@ function GetBzlIndent(lnum) abort
     if exists('g:pyindent_open_paren')
       let l:pyindent_open_paren = g:pyindent_open_paren
     endif
-    " Vim 7.3.693 and later defines a shiftwidth() function to get the effective
-    " shiftwidth value. Fall back to &shiftwidth if the function doesn't exist.
-    let l:sw_expr = exists('*shiftwidth') ? 'shiftwidth()' : '&shiftwidth'
-    let g:pyindent_nested_paren = l:sw_expr . ' * 2'
-    let g:pyindent_open_paren = l:sw_expr . ' * 2'
+    let g:pyindent_nested_paren = 'shiftwidth() * 2'
+    let g:pyindent_open_paren = 'shiftwidth() * 2'
   endif
 
   let l:indent = -1
index 5ec2a7b21ac277bc4897034122a15113337d2c8e..5fae7b904603316351dbd88aca1c8a2b36d0a65e 100644 (file)
@@ -47,7 +47,7 @@ fun! CdlGetIndent(lnum)
   let thisline = getline(a:lnum)
   if match(thisline, '^\s*\(\k\+\|\[[^]]*]\)\s*\(,\|;\s*$\)') >= 0
     " it's an attributes line
-    return &sw
+    return shiftwidth()
   elseif match(thisline, '^\c\s*\([{}]\|\/[*/]\|dimension\|schedule\|group\|hierarchy\|class\)') >= 0
     " it's a header or '{' or '}' or a comment
     return 0
@@ -71,13 +71,13 @@ fun! CdlGetIndent(lnum)
     let c = line[inicio-1]
     " ')' and '=' don't change indent and are useless to set 'f'
     if c == '{'
-      return &sw
+      return shiftwidth()
     elseif c != ')' && c != '='
       let f = 1 " all but 'elseif' are followed by a formula
       if c ==? 'n' || c ==? 'e' " 'then', 'else'
-       let ind = ind + &sw
+       let ind = ind + shiftwidth()
       elseif strpart(line, inicio-6, 6) ==? 'elseif' " elseif, set f to conditional
-       let ind = ind + &sw
+       let ind = ind + shiftwidth()
        let f = 0
       end
     end
@@ -98,16 +98,16 @@ fun! CdlGetIndent(lnum)
       let ind = 0
       let f = 1
     elseif c == ')' || c== ';' || strpart(line, inicio-5, 5) ==? 'endif'
-      let ind = ind - &sw
+      let ind = ind - shiftwidth()
     elseif c == '(' || c ==? 'f' " '(' or 'if'
-      let ind = ind + &sw
+      let ind = ind + shiftwidth()
     else " c == '='
       " if it is an asignment increase indent
       if f == -1 " we don't know yet, find out
        let f = CdlAsignment(lnum, strpart(line, 0, inicio))
       end
       if f == 1 " formula increase it
-       let ind = ind + &sw
+       let ind = ind + shiftwidth()
       end
     end
   endw
@@ -115,13 +115,13 @@ fun! CdlGetIndent(lnum)
   " CURRENT LINE, if it starts with a closing element, decrease indent
   " or if it starts with '=' (asignment), increase indent
   if match(thisline, '^\c\s*\(else\|then\|endif\|[);]\)') >= 0
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
   elseif match(thisline, '^\s*=') >= 0
     if f == -1 " we don't know yet if is an asignment, find out
       let f = CdlAsignment(lnum, "")
     end
     if f == 1 " formula increase it
-      let ind = ind + &sw
+      let ind = ind + shiftwidth()
     end
   end
 
index 247e1a6e4c67d56eb9c08bc752f082fe8709eea3..445281cc4679074a6280982dc52b9d3d6fcf6465 100644 (file)
@@ -31,19 +31,19 @@ function! GetChaiScriptIndent()
   let flag = 0
   let prevline = getline(lnum)
   if prevline =~ '^.*{.*'
-    let ind = ind + &shiftwidth
+    let ind = ind + shiftwidth()
     let flag = 1
   endif
 
   " Subtract a 'shiftwidth' after lines containing a { followed by a }
   " to keep it balanced
   if flag == 1 && prevline =~ '.*{.*}.*'
-    let ind = ind - &shiftwidth
+    let ind = ind - shiftwidth()
   endif
 
   " Subtract a 'shiftwidth' on lines ending with }
   if getline(v:lnum) =~ '^\s*\%(}\)'
-    let ind = ind - &shiftwidth
+    let ind = ind - shiftwidth()
   endif
 
   return ind
index 7592b10d7d861644e0cbd0cb76c9e53dc4bef150..7c4186e29b4131f92038ba30a35253473732b415 100644 (file)
@@ -261,7 +261,7 @@ if exists("*searchpairpos")
                call cursor(paren)
 
                if s:is_method_special_case(paren)
-                       return [paren[0], paren[1] + &shiftwidth - 1]
+                       return [paren[0], paren[1] + shiftwidth() - 1]
                endif
 
                if s:is_reader_conditional_special_case(paren)
@@ -299,19 +299,19 @@ if exists("*searchpairpos")
                let ww = s:strip_namespace_and_macro_chars(w)
 
                if &lispwords =~# '\V\<' . ww . '\>'
-                       return [paren[0], paren[1] + &shiftwidth - 1]
+                       return [paren[0], paren[1] + shiftwidth() - 1]
                endif
 
                if g:clojure_fuzzy_indent
                        \ && !s:match_one(g:clojure_fuzzy_indent_blacklist, ww)
                        \ && s:match_one(g:clojure_fuzzy_indent_patterns, ww)
-                       return [paren[0], paren[1] + &shiftwidth - 1]
+                       return [paren[0], paren[1] + shiftwidth() - 1]
                endif
 
                call search('\v\_s', 'cW')
                call search('\v\S', 'W')
                if paren[0] < line(".")
-                       return [paren[0], paren[1] + (g:clojure_align_subforms ? 0 : &shiftwidth - 1)]
+                       return [paren[0], paren[1] + (g:clojure_align_subforms ? 0 : shiftwidth() - 1)]
                endif
 
                call search('\v\S', 'bW')
index 421afcb6d75caa459992faa6041989ede444aa1d..93a131b93839f74d96cf8aca33bd9e07d1b2fd4d 100644 (file)
@@ -68,19 +68,19 @@ fun! CMakeGetIndent(lnum)
     let ind = ind
   else
     if previous_line =~? cmake_indent_begin_regex
-      let ind = ind + &sw
+      let ind = ind + shiftwidth()
     endif
     if previous_line =~? cmake_indent_open_regex
-      let ind = ind + &sw
+      let ind = ind + shiftwidth()
     endif
   endif
 
   " Subtract
   if this_line =~? cmake_indent_end_regex
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
   endif
   if previous_line =~? cmake_indent_close_regex
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
   endif
 
   return ind
index 8dce3cd01460a23141e374790aa806abc3f2a50f..c08444ac4085f4b9e43b538a554ce5fa930a430a 100644 (file)
@@ -52,11 +52,11 @@ function! s:optionalblock(lnum,ind,blocks,clauses)
         if getline(lastclause) =~? clauses && s:stripped(lastclause) !~? '^'.begin
             let ind = indent(lastclause)
         elseif lastclause > 0
-            let ind = indent(lastclause) + &sw
-            "let ind = ind + &sw
+            let ind = indent(lastclause) + shiftwidth()
+            "let ind = ind + shiftwidth()
         endif
     elseif line =~? clauses && cline !~? end
-        let ind = ind + &sw
+        let ind = ind + shiftwidth()
     endif
     return ind
 endfunction
@@ -98,8 +98,8 @@ function! GetCobolIndent(lnum) abort
                 let num = matchstr(line,'^\s*\zs\d\+\>')
                 if 0+cnum == num
                     return lindent
-                elseif 0+cnum > num && default < lindent + &sw
-                    let default = lindent + &sw
+                elseif 0+cnum > num && default < lindent + shiftwidth()
+                    let default = lindent + shiftwidth()
                 endif
             elseif lindent < bshft && lindent >= ashft
                 break
@@ -135,13 +135,13 @@ function! GetCobolIndent(lnum) abort
     if line =~? '^PERFORM\>'
         let perfline = substitute(line, '\c^PERFORM\s*', "", "")
         if perfline =~? '^\%(\k\+\s\+TIMES\)\=\s*$'
-            let ind = ind + &sw
+            let ind = ind + shiftwidth()
         elseif perfline =~? '^\%(WITH\s\+TEST\|VARYING\|UNTIL\)\>.*[^.]$'
-            let ind = ind + &sw
+            let ind = ind + shiftwidth()
         endif
     endif
     if line =~? '^\%(IF\|THEN\|ELSE\|READ\|EVALUATE\|SEARCH\|SELECT\)\>'
-        let ind = ind + &sw
+        let ind = ind + shiftwidth()
     endif
     let ind = s:optionalblock(a:lnum,ind,'ADD\|COMPUTE\|DIVIDE\|MULTIPLY\|SUBTRACT','ON\s\+SIZE\s\+ERROR')
     let ind = s:optionalblock(a:lnum,ind,'STRING\|UNSTRING\|ACCEPT\|DISPLAY\|CALL','ON\s\+OVERFLOW\|ON\s\+EXCEPTION')
@@ -157,10 +157,10 @@ function! GetCobolIndent(lnum) abort
             "&& s:stripped(lastclause) !~? '^\%(SEARCH\|EVALUATE\|READ\)\>'
             let ind = indent(lastclause)
         elseif lastclause > 0
-            let ind = indent(lastclause) + &sw
+            let ind = indent(lastclause) + shiftwidth()
         endif
     elseif line =~? '^WHEN\>'
-        let ind = ind + &sw
+        let ind = ind + shiftwidth()
     endif
     "I'm not sure why I had this
     "if line =~? '^ELSE\>-\@!' && line !~? '\.$'
@@ -168,7 +168,7 @@ function! GetCobolIndent(lnum) abort
     "endif
     if cline =~? '^\(END\)\>-\@!'
         " On lines with just END, 'guess' a simple shift left
-        let ind = ind - &sw
+        let ind = ind - shiftwidth()
     elseif cline =~? '^\(END-IF\|THEN\|ELSE\)\>-\@!'
         call cursor(a:lnum,indent(a:lnum))
         let match = searchpair('\c-\@<!\<IF\>','\c-\@<!\%(THEN\|ELSE\)\>','\c-\@<!\<END-IF\>\zs','bnW',s:skip)
@@ -209,7 +209,7 @@ function! GetCobolIndent(lnum) abort
         if match > 0
             let ind = indent(match)
         elseif cline =~? '^\(END-\(READ\|EVALUATE\|SEARCH\|PERFORM\)\)\>'
-            let ind = ind - &sw
+            let ind = ind - shiftwidth()
         endif
     endif
     return ind < bshft ? bshft : ind
index 999b8d6a7663bde45fbf53cc47357f3010e72582..ad28a67a0d1e7be5d84d6afc0fc00596267e461a 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:    Cucumber
 " Maintainer:  Tim Pope <vimNOSPAM@tpope.org>
-" Last Change: 2016 Aug 29
+" Last Change: 2017 Jun 13
 
 if exists("b:did_indent")
   finish
@@ -27,7 +27,7 @@ function! GetCucumberIndent()
   let line  = getline(prevnonblank(v:lnum-1))
   let cline = getline(v:lnum)
   let nline = getline(nextnonblank(v:lnum+1))
-  let sw = exists('*shiftwidth') ? shiftwidth() : &sw
+  let sw = exists('*shiftwidth') ? shiftwidth() : shiftwidth()
   let syn = s:syn(prevnonblank(v:lnum-1))
   let csyn = s:syn(v:lnum)
   let nsyn = s:syn(nextnonblank(v:lnum+1))
index 0afcbeada7352591ed53b1b7b90fb85e0260667e..6811ec4af5584388f3d7ae656319574860d19c70 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:    Dylan
 " Version:     0.01
-" Last Change: 2003 Feb 04
+" Last Change: 2017 Jun 13
 " Maintainer:  Brent A. Fulgham <bfulgham@debian.org>
 
 " Only load this indent file when no other was loaded.
@@ -45,13 +45,13 @@ function DylanGetIndent()
 
   " If previous line was a 'define', indent
   if prevline =~? '\(^\s*\(begin\|block\|case\|define\|else\|elseif\|for\|finally\|if\|select\|unless\|while\)\|\s*\S*\s*=>$\)'
-    let chg = &sw
+    let chg = shiftwidth()
   " local methods indent the shift-width, plus 6 for the 'local'
   elseif prevline =~? '^\s*local'
-    let chg = &sw + 6
+    let chg = shiftwidth() + 6
   " If previous line was a let with no closing semicolon, indent
   elseif prevline =~? '^\s*let.*[^;]\s*$'
-    let chg = &sw
+    let chg = shiftwidth()
   " If previous line opened a parenthesis, and did not close it, indent
   elseif prevline =~ '^.*(\s*[^)]*\((.*)\)*[^)]*$'
     return = match( prevline, '(.*\((.*)\|[^)]\)*.*$') + 1
@@ -75,13 +75,13 @@ function DylanGetIndent()
     " line doesn't start with an indentable command:
     let curr_str = getline(curr_line)
     if curr_str =~? '^\s*\(begin\|block\|case\|define\|else\|elseif\|for\|finally\|if\|select\|unless\|while\)'
-      let chg = &sw
+      let chg = shiftwidth()
     endif
   endif
 
   " If a line starts with end, un-indent (even if we just indented!)
   if cline =~? '^\s*\(cleanup\|end\|else\|elseif\|exception\|finally\|otherwise\)'
-    let chg = chg - &sw
+    let chg = chg - shiftwidth()
   endif
 
   return ind + chg
index 7569fe9106551e14dcd2970257591fe7ebc485b5..9228f186834f1c4881a7579bc148c949c540e91a 100644 (file)
@@ -669,7 +669,7 @@ function! s:BeginningOfClauseFound(stack, token, stored_vcol)
     call s:Pop(a:stack)
     if empty(a:stack)
       call s:Log('    Stack is ["when"], so LTI is in a guard -> return')
-      return [1, a:stored_vcol + &sw + 2]
+      return [1, a:stored_vcol + shiftwidth() + 2]
     else
       return [1, s:UnexpectedToken(a:token, a:stack)]
     endif
@@ -678,7 +678,7 @@ function! s:BeginningOfClauseFound(stack, token, stored_vcol)
     call s:Pop(a:stack)
     if empty(a:stack)
       call s:Log('    Stack is ["->"], so LTI is in function body -> return')
-      return [1, a:stored_vcol + &sw]
+      return [1, a:stored_vcol + shiftwidth()]
     elseif a:stack[0] ==# ';'
       call s:Pop(a:stack)
       if empty(a:stack)
@@ -797,7 +797,7 @@ function! s:ErlangCalcIndent2(lnum, stack)
 
       elseif token ==# 'begin'
         let [ret, res] = s:BeginElementFound(stack, token, curr_vcol,
-                                            \stored_vcol, 'end', &sw)
+                                            \stored_vcol, 'end', shiftwidth())
         if ret | return res | endif
 
       " case EXPR of BRANCHES end
@@ -848,11 +848,11 @@ function! s:ErlangCalcIndent2(lnum, stack)
         elseif stack == ['->']
           call s:Log('    LTI is in a branch after ' .
                     \'"of/receive/after/if/catch" -> return')
-          return stored_vcol + &sw
+          return stored_vcol + shiftwidth()
         elseif stack == ['when']
           call s:Log('    LTI is in a guard after ' .
                     \'"of/receive/after/if/catch" -> return')
-          return stored_vcol + &sw
+          return stored_vcol + shiftwidth()
         else
           return s:UnexpectedToken(token, stack)
         endif
@@ -888,7 +888,7 @@ function! s:ErlangCalcIndent2(lnum, stack)
           if empty(stack)
             call s:Log('    LTI is in a condition; matching ' .
                       \'"case/if/try/receive" found')
-            let stored_vcol = curr_vcol + &sw
+            let stored_vcol = curr_vcol + shiftwidth()
           elseif stack[0] ==# 'align_to_begin_element'
             call s:Pop(stack)
             let stored_vcol = curr_vcol
@@ -897,23 +897,23 @@ function! s:ErlangCalcIndent2(lnum, stack)
                       \'"case/if/try/receive" found')
             call s:Pop(stack)
             call s:Pop(stack)
-            let stored_vcol = curr_vcol + &sw
+            let stored_vcol = curr_vcol + shiftwidth()
           elseif stack[0] ==# '->'
             call s:Log('    LTI is in a branch; matching ' .
                       \'"case/if/try/receive" found')
             call s:Pop(stack)
-            let stored_vcol = curr_vcol + 2 * &sw
+            let stored_vcol = curr_vcol + 2 * shiftwidth()
           elseif stack[0] ==# 'when'
             call s:Log('    LTI is in a guard; matching ' .
                       \'"case/if/try/receive" found')
             call s:Pop(stack)
-            let stored_vcol = curr_vcol + 2 * &sw + 2
+            let stored_vcol = curr_vcol + 2 * shiftwidth() + 2
           endif
 
         endif
 
         let [ret, res] = s:BeginElementFound(stack, token, curr_vcol,
-                                            \stored_vcol, 'end', &sw)
+                                            \stored_vcol, 'end', shiftwidth())
         if ret | return res | endif
 
       elseif token ==# 'fun'
@@ -930,7 +930,7 @@ function! s:ErlangCalcIndent2(lnum, stack)
           " stack = ['when']  =>  LTI is in a guard
           if empty(stack)
             call s:Log('    LTI is in a condition; matching "fun" found')
-            let stored_vcol = curr_vcol + &sw
+            let stored_vcol = curr_vcol + shiftwidth()
           elseif len(stack) > 1 && stack[0] ==# '->' && stack[1] ==# ';'
             call s:Log('    LTI is in a condition; matching "fun" found')
             call s:Pop(stack)
@@ -938,15 +938,15 @@ function! s:ErlangCalcIndent2(lnum, stack)
           elseif stack[0] ==# '->'
             call s:Log('    LTI is in a branch; matching "fun" found')
             call s:Pop(stack)
-            let stored_vcol = curr_vcol + 2 * &sw
+            let stored_vcol = curr_vcol + 2 * shiftwidth()
           elseif stack[0] ==# 'when'
             call s:Log('    LTI is in a guard; matching "fun" found')
             call s:Pop(stack)
-            let stored_vcol = curr_vcol + 2 * &sw + 2
+            let stored_vcol = curr_vcol + 2 * shiftwidth() + 2
           endif
 
           let [ret, res] = s:BeginElementFound(stack, token, curr_vcol,
-                                              \stored_vcol, 'end', &sw)
+                                              \stored_vcol, 'end', shiftwidth())
           if ret | return res | endif
         else
           " Pass: we have a function reference (e.g. "fun f/0")
@@ -1220,7 +1220,7 @@ function! s:ErlangCalcIndent2(lnum, stack)
             "   when A,
             "        LTI
             let [ret, res] = s:BeginElementFoundIfEmpty(stack, token, curr_vcol,
-                                                       \stored_vcol, &sw)
+                                                       \stored_vcol, shiftwidth())
             if ret | return res | endif
           else
             " Example:
@@ -1252,7 +1252,7 @@ function! s:ErlangCalcIndent2(lnum, stack)
           " If LTI is between an 'after' and the corresponding
           " 'end', then let's return
           let [ret, res] = s:BeginElementFoundIfEmpty(stack, token, curr_vcol,
-                                                     \stored_vcol, &sw)
+                                                     \stored_vcol, shiftwidth())
           if ret | return res | endif
         endif
 
index afabd4fe5b16335330b96057bcad43067edda097..505832549538a9fe7b14fd1779c816aee4cacaa7 100644 (file)
@@ -47,11 +47,7 @@ set cpo&vim
 
 function! GetErubyIndent(...)
   " The value of a single shift-width
-  if exists('*shiftwidth')
-    let sw = shiftwidth()
-  else
-    let sw = &sw
-  endif
+  let sw = shiftwidth()
 
   if a:0 && a:1 == '.'
     let v:lnum = line('.')
index 84b16d55f0d5228981af90ef05465a4def8d6373..b34e7cfd475b885c92750dd1c3fb933f17f56c7d 100644 (file)
@@ -339,7 +339,7 @@ function FalconGetIndent(...)
 
     " If the previous line ended with a block opening, add a level of indent.
     if s:Match(lnum, s:block_regex)
-       return indent(s:GetMSL(lnum)) + &sw
+       return indent(s:GetMSL(lnum)) + shiftwidth()
     endif
 
     " If it contained hanging closing brackets, find the rightmost one, find its
@@ -350,20 +350,20 @@ function FalconGetIndent(...)
        if opening.pos != -1
            if opening.type == '(' && searchpair('(', '', ')', 'bW', s:skip_expr) > 0
                if col('.') + 1 == col('$')
-                   return ind + &sw
+                   return ind + shiftwidth()
                else
                    return virtcol('.')
                endif
            else
                let nonspace = matchend(line, '\S', opening.pos + 1) - 1
-               return nonspace > 0 ? nonspace : ind + &sw
+               return nonspace > 0 ? nonspace : ind + shiftwidth()
            endif
        elseif closing.pos != -1
            call cursor(lnum, closing.pos + 1)
            normal! %
 
            if s:Match(line('.'), s:falcon_indent_keywords)
-               return indent('.') + &sw
+               return indent('.') + shiftwidth()
            else
                return indent('.')
            endif
@@ -392,7 +392,7 @@ function FalconGetIndent(...)
     let col = s:Match(lnum, s:falcon_indent_keywords)
     if col > 0
        call cursor(lnum, col)
-       let ind = virtcol('.') - 1 + &sw
+       let ind = virtcol('.') - 1 + shiftwidth()
        " TODO: make this better (we need to count them) (or, if a searchpair
        " fails, we know that something is lacking an end and thus we indent a
        " level
@@ -422,9 +422,9 @@ function FalconGetIndent(...)
     " TODO: this does not take into account contrived things such as
     " module Foo; class Bar; end
     if s:Match(lnum, s:falcon_indent_keywords)
-       let ind = msl_ind + &sw
+       let ind = msl_ind + shiftwidth()
        if s:Match(lnum, s:end_end_regex)
-           let ind = ind - &sw
+           let ind = ind - shiftwidth()
        endif
        return ind
     endif
@@ -433,7 +433,7 @@ function FalconGetIndent(...)
     " closing bracket, indent one extra level.
     if s:Match(lnum, s:non_bracket_continuation_regex) && !s:Match(lnum, '^\s*\([\])}]\|end\)')
        if lnum == p_lnum
-           let ind = msl_ind + &sw
+           let ind = msl_ind + shiftwidth()
        else
            let ind = msl_ind
        endif
index 480c96d1b9fd4e2078c7816fd5bfb80cef22a8c5..6a670ee271620b28abd404326fa526b1f0e7c098 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:    git config file
 " Maintainer:  Tim Pope <vimNOSPAM@tpope.org>
-" Last Change: 2016 Aug 29
+" Last Change: 2017 Jun 13
 
 if exists("b:did_indent")
   finish
@@ -20,7 +20,7 @@ if exists("*GetGitconfigIndent")
 endif
 
 function! GetGitconfigIndent()
-  let sw    = exists('*shiftwidth') ? shiftwidth() : &sw
+  let sw    = shiftwidth()
   let line  = getline(prevnonblank(v:lnum-1))
   let cline = getline(v:lnum)
   if line =~  '\\\@<!\%(\\\\\)*\\$'
index 33b7c9f312d28d3d031bdc9d30e155c90b78561c..2d24b592d0edef00ada87ef8ef167edd279e52fa 100644 (file)
@@ -2,7 +2,7 @@
 " Language:    gitolite configuration
 " URL:         https://github.com/tmatilai/gitolite.vim
 " Maintainer:  Teemu Matilainen <teemu.matilainen@iki.fi>
-" Last Change: 2011-12-24
+" Last Change: 2017 Jun 13
 
 if exists("b:did_indent")
   finish
@@ -27,11 +27,11 @@ function! GetGitoliteIndent()
   let cline = getline(v:lnum)
 
   if cline =~ '^\s*\(C\|R\|RW\|RW+\|RWC\|RW+C\|RWD\|RW+D\|RWCD\|RW+CD\|-\)[ \t=]'
-    return &sw
+    return shiftwidth()
   elseif cline =~ '^\s*config\s'
-    return &sw
+    return shiftwidth()
   elseif pline =~ '^\s*repo\s' && cline =~ '^\s*\(#.*\)\?$'
-    return &sw
+    return shiftwidth()
   elseif cline =~ '^\s*#'
     return indent(prevln)
   elseif cline =~ '^\s*$'
index 412ac871c49ebd81c69bf4267c04bfde9675dfde..bf9ff75e6c6ca6eb7efd6016390a13db298f6b9e 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:    Go
 " Maintainer:  David Barnett (https://github.com/google/vim-ft-go)
-" Last Change: 2014 Aug 16
+" Last Change: 2017 Jun 13
 "
 " TODO:
 " - function invocations split across lines
@@ -23,18 +23,6 @@ if exists('*GoIndent')
   finish
 endif
 
-" The shiftwidth() function is relatively new.
-" Don't require it to exist.
-if exists('*shiftwidth')
-  function s:sw() abort
-    return shiftwidth()
-  endfunction
-else
-  function s:sw() abort
-    return &shiftwidth
-  endfunction
-endif
-
 function! GoIndent(lnum)
   let l:prevlnum = prevnonblank(a:lnum-1)
   if l:prevlnum == 0
@@ -51,17 +39,17 @@ function! GoIndent(lnum)
 
   if l:prevl =~ '[({]\s*$'
     " previous line opened a block
-    let l:ind += s:sw()
+    let l:ind += shiftwidth()
   endif
   if l:prevl =~# '^\s*\(case .*\|default\):$'
     " previous line is part of a switch statement
-    let l:ind += s:sw()
+    let l:ind += shiftwidth()
   endif
   " TODO: handle if the previous line is a label.
 
   if l:thisl =~ '^\s*[)}]'
     " this line closed a block
-    let l:ind -= s:sw()
+    let l:ind -= shiftwidth()
   endif
 
   " Colons are tricky.
@@ -69,7 +57,7 @@ function! GoIndent(lnum)
   " We ignore trying to deal with jump labels because (a) they're rare, and
   " (b) they're hard to disambiguate from a composite literal key.
   if l:thisl =~# '^\s*\(case .*\|default\):$'
-    let l:ind -= s:sw()
+    let l:ind -= shiftwidth()
   endif
 
   return l:ind
index c3935af9e9d364f2e7f5746f0af3889bb7224a90..e6416e6f53c4e9dfa4a5ddbfb1ed7d3de462974b 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:    Haml
 " Maintainer:  Tim Pope <vimNOSPAM@tpope.org>
-" Last Change: 2016 Aug 29
+" Last Change: 2017 Jun 13
 
 if exists("b:did_indent")
   finish
@@ -37,7 +37,7 @@ function! GetHamlIndent()
   let line = substitute(line,'^\s\+','','')
   let indent = indent(lnum)
   let cindent = indent(v:lnum)
-  let sw = exists('*shiftwidth') ? shiftwidth() : &sw
+  let sw = shiftwidth()
   if cline =~# '\v^-\s*%(elsif|else|when)>'
     let indent = cindent < indent ? cindent : indent - sw
   endif
index 93e7db486eee10ea4d277fd627c11aa5d0ccb442..b27a1739246b091ada0e7c2fa38900c097945aed 100644 (file)
@@ -27,13 +27,13 @@ function HamGetIndent(lnum)
   " Add a shiftwidth to statements following if,  else, elseif,
   " case, select, default, do, until, while, for, start
   if prevline =~? '^\s*\<\(if\|else\%(if\)\?\|for\|repeat\|do\|while\|sub\)\>' 
-    let ind = ind + &sw
+    let ind = ind + shiftwidth()
   endif
 
   " Subtract a shiftwidth from else, elseif, end(if|while|for), until
   let line = getline(v:lnum)
   if line =~? '^\s*\(else\|elseif\|loop\|until\|end\%(if\|while\|for\|sub\)\)\>'
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
   endif
 
   return ind
index 02ac7d4d1b5a4d956877cfb6eba4ae0fe02fabe2..ece587d46fc4ffacbfc21ff5cc5acf232ec6a145 100644 (file)
@@ -47,7 +47,7 @@ function GetHogIndent()
     " Continuation of a line that wasn't indented
     let prevline = getline(prevlnum)
     if prevline =~ '^\k\+.*\\\s*$'
-        return &sw 
+        return shiftwidth() 
     endif
 
     " Continuation of a line that was indented
@@ -58,13 +58,13 @@ function GetHogIndent()
     " Indent the next line if previous line contained a start of a block
     " definition ('{' or '(').
     if prevline =~ '^\k\+[^#]*{}\@!\s*$' " TODO || prevline =~ '^\k\+[^#]*()\@!\s*$'
-        return &sw
+        return shiftwidth()
     endif
 
     " Match inside of a block
     if s:IsInBlock(v:lnum)
         if prevline =~ "^\k\+.*$"
-            return &sw
+            return shiftwidth()
         else
             return indent(prevlnum)
         endif
index 57ba53ecd4ebdd86df1b8ab8f52feadb84f1cf86..37697841fddddf872f221ca093783d873d984a01 100644 (file)
@@ -2,7 +2,7 @@
 " Header: "{{{
 " Maintainer:  Bram Moolenaar
 " Original Author: Andy Wokula <anwoku@yahoo.de>
-" Last Change: 2017 Jan 17
+" Last Change: 2017 Jun 13
 " Version:     1.0
 " Description: HTML indent script with cached state for faster indenting on a
 "              range of lines.
@@ -51,15 +51,6 @@ if exists("*HtmlIndent") && !exists('g:force_reload_html')
   finish
 endif
 
-" shiftwidth() exists since patch 7.3.694
-if exists('*shiftwidth')
-  let s:ShiftWidth = function('shiftwidth')
-else
-  func! s:ShiftWidth()
-    return &shiftwidth
-  endfunc
-endif
-
 " Allow for line continuation below.
 let s:cpo_save = &cpo
 set cpo-=C
@@ -123,7 +114,7 @@ func! HtmlIndent_CheckUserSettings()
 
   let indone = {"zero": 0
               \,"auto": "indent(prevnonblank(v:lnum-1))"
-              \,"inc": "b:hi_indent.blocktagind + s:ShiftWidth()"}
+              \,"inc": "b:hi_indent.blocktagind + shiftwidth()"}
 
   let script1 = ''
   if exists("b:html_indent_script1")
@@ -358,7 +349,7 @@ func! s:CheckBlockTag(blocktag, ind)
     endif
     let b:hi_newstate.blocklnr = v:lnum
     " save allover indent for the endtag
-    let b:hi_newstate.blocktagind = b:hi_indent.baseindent + (s:nextrel + s:curind) * s:ShiftWidth()
+    let b:hi_newstate.blocktagind = b:hi_indent.baseindent + (s:nextrel + s:curind) * shiftwidth()
     if a:ind == 3
       return "SCRIPT"    " all except this must be lowercase
       " line is to be checked again for the type attribute
@@ -480,7 +471,7 @@ func! s:FreshState(lnum)
       let state.blocklnr = stopline
       " check preceding tags in the line:
       call s:CountITags(tagline[: stopcol-2])
-      let state.blocktagind = indent(stopline) + (s:curind + s:nextrel) * s:ShiftWidth()
+      let state.blocktagind = indent(stopline) + (s:curind + s:nextrel) * shiftwidth()
       return state
     elseif stopline == state.lnum
       " handle special case: previous line (= state.lnum) contains a
@@ -490,7 +481,7 @@ func! s:FreshState(lnum)
       if !swendtag
         let [bline, bcol] = searchpos('<'.blocktag[1:].'\>', "bnW")
         call s:CountITags(tolower(getline(bline)[: bcol-2]))
-        let state.baseindent = indent(bline) + (s:curind + s:nextrel) * s:ShiftWidth()
+        let state.baseindent = indent(bline) + (s:curind + s:nextrel) * shiftwidth()
         return state
       endif
     endif
@@ -511,7 +502,7 @@ func! s:FreshState(lnum)
     if found == 2
       let state.baseindent = b:hi_indent.baseindent
     endif
-    let state.blocktagind = indent(comlnum) + (s:curind + s:nextrel) * s:ShiftWidth()
+    let state.blocktagind = indent(comlnum) + (s:curind + s:nextrel) * shiftwidth()
     return state
   endif
 
@@ -530,7 +521,7 @@ func! s:FreshState(lnum)
       let text = tolower(getline(comlnum)[: comcol-2])
     endif
     call s:CountITags(text)
-    let state.baseindent = indent(comlnum) + (s:curind + s:nextrel) * s:ShiftWidth()
+    let state.baseindent = indent(comlnum) + (s:curind + s:nextrel) * shiftwidth()
     " TODO check tags that follow "-->"
     return state
   endif
@@ -550,9 +541,9 @@ func! s:FreshState(lnum)
         let text = getline(start_lnum)
         let swendtag = match(text, '^\s*</') >= 0
         call s:CountITags(text[: col('.') - 2])
-        let state.baseindent += s:nextrel * s:ShiftWidth()
+        let state.baseindent += s:nextrel * shiftwidth()
         if !swendtag
-          let state.baseindent += s:curind * s:ShiftWidth()
+          let state.baseindent += s:curind * shiftwidth()
         endif
       endif
       return state
@@ -565,9 +556,9 @@ func! s:FreshState(lnum)
   let text = getline(state.lnum)
   let swendtag = match(text, '^\s*</') >= 0
   call s:CountITags(tolower(text))
-  let state.baseindent = indent(state.lnum) + s:nextrel * s:ShiftWidth()
+  let state.baseindent = indent(state.lnum) + s:nextrel * shiftwidth()
   if !swendtag
-    let state.baseindent += s:curind * s:ShiftWidth()
+    let state.baseindent += s:curind * shiftwidth()
   endif
   return state
 endfunc "}}}
@@ -646,7 +637,7 @@ func! s:CSSIndent()
 
   " add indent after {
   let brace_counts = HtmlIndent_CountBraces(prev_lnum)
-  let extra = brace_counts.c_open * s:ShiftWidth()
+  let extra = brace_counts.c_open * shiftwidth()
 
   let prev_text = getline(prev_lnum)
   let below_end_brace = prev_text =~ '}\s*$'
@@ -663,7 +654,7 @@ func! s:CSSIndent()
       " if the current line is not a comment or starts with @ (used by template
       " systems) reduce indent if previous line is a continuation line
       if !prev_hasfield && !prev_special
-        let extra = -s:ShiftWidth()
+        let extra = -shiftwidth()
       endif
     else
       let cur_hasfield = curtext =~ '^\s*[a-zA-Z0-9-]\+:'
@@ -671,14 +662,14 @@ func! s:CSSIndent()
       if !cur_hasfield && (prev_hasfield || prev_unfinished)
         " Continuation line has extra indent if the previous line was not a
         " continuation line.
-        let extra = s:ShiftWidth()
+        let extra = shiftwidth()
         " Align with @if
         if prev_text =~ '^\s*@if '
           let extra = 4
         endif
       elseif cur_hasfield && !prev_hasfield && !prev_special
         " less indent below a continuation line
-        let extra = -s:ShiftWidth()
+        let extra = -shiftwidth()
       endif
     endif
   endif
@@ -699,10 +690,10 @@ func! s:CSSIndent()
     if special
       " do not reduce indent below @{ ... }
       if extra < 0
-        let extra += s:ShiftWidth()
+        let extra += shiftwidth()
       endif
     else
-      let extra -= (brace_counts.c_close - (prev_text =~ '^\s*}')) * s:ShiftWidth()
+      let extra -= (brace_counts.c_close - (prev_text =~ '^\s*}')) * shiftwidth()
     endif
   endif
 
@@ -710,10 +701,10 @@ func! s:CSSIndent()
   if extra == 0
     if brace_counts.p_open > brace_counts.p_close
       " previous line has more ( than ): add a shiftwidth
-      let extra = s:ShiftWidth()
+      let extra = shiftwidth()
     elseif brace_counts.p_open < brace_counts.p_close
       " previous line has more ) than (: subtract a shiftwidth
-      let extra = -s:ShiftWidth()
+      let extra = -shiftwidth()
     endif
   endif
 
@@ -816,7 +807,7 @@ func! s:Alien5()
   let idx = match(prevtext, '^\s*\zs<!--')
   if idx >= 0
     " just below comment start, add a shiftwidth
-    return idx + s:ShiftWidth()
+    return idx + shiftwidth()
   endif
 
   " Some files add 4 spaces just below a TODO line.  It's difficult to detect
@@ -837,7 +828,7 @@ func! s:Alien6()
       return indent(lnum)
     endif
   endif
-  return b:hi_indent.baseindent + s:ShiftWidth()
+  return b:hi_indent.baseindent + shiftwidth()
 endfunc "}}}
 
 " When the "lnum" line ends in ">" find the line containing the matching "<".
@@ -947,7 +938,7 @@ func! HtmlIndent()
   endif
 
   let curtext = tolower(getline(v:lnum))
-  let indentunit = s:ShiftWidth()
+  let indentunit = shiftwidth()
 
   let b:hi_newstate = {}
   let b:hi_newstate.lnum = v:lnum
@@ -1030,9 +1021,9 @@ func! HtmlIndent()
         if col('.') > 2
           let swendtag = match(text, '^\s*</') >= 0
           call s:CountITags(text[: col('.') - 2])
-          let indent += s:nextrel * s:ShiftWidth()
+          let indent += s:nextrel * shiftwidth()
           if !swendtag
-            let indent += s:curind * s:ShiftWidth()
+            let indent += s:curind * shiftwidth()
           endif
         endif
       else
index b4c6ae6feaae59c04b220d054d02a2d339f6d8d7..7402e8688ef4a83196ef2297258cca7ba2580718 100644 (file)
@@ -1,6 +1,6 @@
 " IDL (Interactive Data Language) indent file.
 " Language: IDL (ft=idlang)
-" Last change: 2012 May 18
+" Last change: 2017 Jun 13
 " Maintainer: Aleksandar Jelenak <ajelenak AT yahoo.com>
 
 " Only load this indent file when no other was loaded.
@@ -34,25 +34,25 @@ function GetIdlangIndent(lnum)
    " Indenting of continued lines.
    if getline(pnum) =~ '\$\s*\(;.*\)\=$'
       if getline(pnum2) !~ '\$\s*\(;.*\)\=$'
-        let curind = curind+&sw
+        let curind = curind+shiftwidth()
       endif
    else
       if getline(pnum2) =~ '\$\s*\(;.*\)\=$'
-        let curind = curind-&sw
+        let curind = curind-shiftwidth()
       endif
    endif
 
    " Indenting blocks of statements.
    if getline(v:lnum) =~? '^\s*\(endif\|endelse\|endwhile\|endfor\|endrep\)\>'
       if getline(pnum) =~? 'begin\>'
-      elseif indent(v:lnum) > curind-&sw
-        let curind = curind-&sw
+      elseif indent(v:lnum) > curind-shiftwidth()
+        let curind = curind-shiftwidth()
       else
         return -1
       endif
    elseif getline(pnum) =~? 'begin\>'
-      if indent(v:lnum) < curind+&sw
-        let curind = curind+&sw
+      if indent(v:lnum) < curind+shiftwidth()
+        let curind = curind+shiftwidth()
       else
         return -1
       endif
index f55f7dc79c790ed48139d92fc3cfecd2b78569d9..531244b81908286dcebfb3df1766d3b0713afe64 100644 (file)
@@ -50,17 +50,17 @@ fun! GetIshdIndent(lnum)
 
     " Add
     if previous_line =~ '^\s*\<\(function\|begin\|switch\|case\|default\|if.\{-}then\|else\|elseif\|while\|repeat\)\>'
-       let ind = ind + &sw
+       let ind = ind + shiftwidth()
     endif
 
     " Subtract
     if this_line =~ '^\s*\<endswitch\>'
-       let ind = ind - 2 * &sw
+       let ind = ind - 2 * shiftwidth()
     elseif this_line =~ '^\s*\<\(begin\|end\|endif\|endwhile\|else\|elseif\|until\)\>'
-       let ind = ind - &sw
+       let ind = ind - shiftwidth()
     elseif this_line =~ '^\s*\<\(case\|default\)\>'
        if previous_line !~ '^\s*\<switch\>'
-           let ind = ind - &sw
+           let ind = ind - shiftwidth()
        endif
     endif
 
index 304c0fe24f4c14853a6eb99ee763df774a9f7d88..3b3f3a104d524276390a10426f3548418b925d8f 100644 (file)
@@ -236,9 +236,10 @@ function s:OneScope(lnum)
         \ s:save_pos('s:previous_token') != '.'
 endfunction
 
-" returns braceless levels started by 'i' and above lines * &sw. 'num' is the
-" lineNr which encloses the entire context, 'cont' if whether line 'i' + 1 is
-" a continued expression, which could have started in a braceless context
+" returns braceless levels started by 'i' and above lines * shiftwidth().
+" 'num' is the lineNr which encloses the entire context, 'cont' if whether
+" line 'i' + 1 is a continued expression, which could have started in a
+" braceless context
 function s:iscontOne(i,num,cont)
   let [l:i, l:num, bL] = [a:i, a:num + !a:num, 0]
   let pind = a:num ? indent(l:num) + s:W : 0
index 649f2b8aa5537a190ccbe73fdd79d7d97621dbbc..b66a03d81bec7f5599d063de7b62c3c87caf8619 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:            JSON
 " Mantainer:           Eli Parra <eli@elzr.com> https://github.com/elzr/vim-json
-" Last Change:          2014 Aug 29
+" Last Change:          2017 Jun 13
 "   https://github.com/jakar/vim-json/commit/20b650e22aa750c4ab6a66aa646bdd95d7cd548a#diff-e81fc111b2052e306d126bd9989f7b7c
 " Original Author:     Rogerz Zhang <rogerz.zhang at gmail.com> http://github.com/rogerz/vim-json
 " Acknowledgement:      Based off of vim-javascript maintained by Darrick Wiebe 
@@ -141,7 +141,7 @@ function GetJSONIndent()
 
   " If the previous line ended with a block opening, add a level of indent.
   " if s:Match(lnum, s:block_regex)
-    " return indent(lnum) + &sw
+    " return indent(lnum) + shiftwidth()
   " endif
 
   " If the previous line contained an opening bracket, and we are still in it,
@@ -149,7 +149,7 @@ function GetJSONIndent()
   if line =~ '[[({]'
     let counts = s:LineHasOpeningBrackets(lnum)
     if counts[0] == '1' || counts[1] == '1' || counts[2] == '1'
-      return ind + &sw
+      return ind + shiftwidth()
     else
       call cursor(v:lnum, vcol)
     end
index f8e1c83079657282d0993840560944a5aa46bbdb..7beb0388d1085a905e8b08991de1905dfb564cbe 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:     Liquid
 " Maintainer:   Tim Pope <vimNOSPAM@tpope.org>
-" Last Change: 2016 Aug 29
+" Last Change: 2017 Jun 13
 
 if exists('b:did_indent')
   finish
@@ -54,7 +54,7 @@ function! GetLiquidIndent(...)
   let line  = substitute(line,'\C^\%(\s*{%\s*end\w*\s*%}\)\+','','')
   let line .= matchstr(cline,'\C^\%(\s*{%\s*end\w*\s*%}\)\+')
   let cline = substitute(cline,'\C^\%(\s*{%\s*end\w*\s*%}\)\+','','')
-  let sw = exists('*shiftwidth') ? shiftwidth() : &sw
+  let sw = shiftwidth()
   let ind += sw * s:count(line,'{%\s*\%(if\|elsif\|else\|unless\|ifchanged\|case\|when\|for\|empty\|tablerow\|capture\)\>')
   let ind -= sw * s:count(line,'{%\s*end\%(if\|unless\|ifchanged\|case\|for\|tablerow\|capture\)\>')
   let ind -= sw * s:count(cline,'{%\s*\%(elsif\|else\|when\|empty\)\>')
index 99e6ec896b9768baf7262cdf5bf5a77459a283d4..5b69663e1d918bec854c63b6dc8fcfbac70c01ad 100644 (file)
@@ -38,24 +38,24 @@ function! GetLogtalkIndent()
        endif
        " Check for entity opening directive on previous line
        if pline =~ '^\s*:-\s\(object\|protocol\|category\)\ze(.*,$'
-               let ind = ind + &sw
+               let ind = ind + shiftwidth()
        " Check for clause head on previous line
        elseif pline =~ ':-\s*\(%.*\)\?$'
-               let ind = ind + &sw
+               let ind = ind + shiftwidth()
        " Check for entity closing directive on previous line
        elseif pline =~ '^\s*:-\send_\(object\|protocol\|category\)\.\(%.*\)\?$'
-               let ind = ind - &sw
+               let ind = ind - shiftwidth()
        " Check for end of clause on previous line
        elseif pline =~ '\.\s*\(%.*\)\?$'
-               let ind = ind - &sw
+               let ind = ind - shiftwidth()
        endif
        " Check for opening conditional on previous line
        if pline =~ '^\s*\([(;]\|->\)' && pline !~ '\.\s*\(%.*\)\?$' && pline !~ '^.*\([)][,]\s*\(%.*\)\?$\)'
-               let ind = ind + &sw
+               let ind = ind + shiftwidth()
        endif
        " Check for closing an unclosed paren, or middle ; or ->
        if line =~ '^\s*\([);]\|->\)'
-               let ind = ind - &sw
+               let ind = ind - shiftwidth()
        endif
        return ind
 endfunction
index d1d2c0d600fee30ded74bba6e532424fe039b70d..604cd333c93ee664f81ec5df0cdaa7c23439fc4f 100644 (file)
@@ -2,7 +2,7 @@
 " Language:    Lua script
 " Maintainer:  Marcus Aurelius Farias <marcus.cf 'at' bol.com.br>
 " First Author:        Max Ischenko <mfi 'at' ukr.net>
-" Last Change: 2016 Jan 10
+" Last Change: 2017 Jun 13
 
 " Only load this indent file when no other was loaded.
 if exists("b:did_indent")
@@ -48,7 +48,7 @@ function! GetLuaIndent()
     " Add 'shiftwidth' if what we found previously is not in a comment and
     " an "end" or "until" is not present on the same line.
     if synIDattr(synID(prevlnum, midx + 1, 1), "name") != "luaComment" && prevline !~ '\<end\>\|\<until\>'
-      let ind = ind + &shiftwidth
+      let ind = ind + shiftwidth()
     endif
   endif
 
@@ -56,7 +56,7 @@ function! GetLuaIndent()
   " This is the part that requires 'indentkeys'.
   let midx = match(getline(v:lnum), '^\s*\%(end\>\|else\>\|elseif\>\|until\>\|}\)')
   if midx != -1 && synIDattr(synID(v:lnum, midx + 1, 1), "name") != "luaComment"
-    let ind = ind - &shiftwidth
+    let ind = ind - shiftwidth()
   endif
 
   return ind
index 7bccc7c0a7f2476ef296726cb0011e96b9d1ef6c..6a316243898c487a28b58f75d5992cc3f35a7833 100644 (file)
@@ -44,9 +44,9 @@ function GetMatlabIndent(lnum)
     " See if this line does not follow the line right after an openblock
     if getline(plnum) =~ '^\s*\(for\|if\|else\|elseif\|case\|while\|switch\|try\|otherwise\|catch\)\>'
     " See if the user has already dedented
-    elseif indent(v:lnum) > curind - &sw
+    elseif indent(v:lnum) > curind - shiftwidth()
       " If not, recommend one dedent
-       let curind = curind - &sw
+       let curind = curind - shiftwidth()
     else
       " Otherwise, trust the user
       return -1
@@ -56,9 +56,9 @@ function GetMatlabIndent(lnum)
   " If the previous line opened a block
   elseif getline(plnum) =~ '^\s*\(for\|if\|else\|elseif\|case\|while\|switch\|try\|otherwise\|catch\)\>'
     " See if the user has already indented
-    if indent(v:lnum) < curind + &sw
+    if indent(v:lnum) < curind + shiftwidth()
       "If not, recommend indent
-      let curind = curind + &sw
+      let curind = curind + shiftwidth()
     else
       " Otherwise, trust the user
       return -1
index 356b87618d8f9bf121847e3cec674f67693b7e56..8298ad98cdf2cb45a1a43e9709c1a376e5ff490c 100644 (file)
@@ -49,7 +49,7 @@ function GetMmaIndent()
     " also, indent only if this line if this line isn't starting a new
     " block... TODO - fix this with indentkeys?
     if getline(v:lnum-1) =~ '\\\@<!\%(\[[^\]]*\|([^)]*\|{[^}]*\)$' && getline(v:lnum) !~ '\s\+[\[({]'
-        let ind = ind+&sw
+        let ind = ind+shiftwidth()
     endif
 
     " if this line had unmatched closing block,
index 3bd65c63f0208fb05c69d06808e986dbd5d9871c..8fe9de3d6118cbb5644ddbdffe7de4c3f9f2cb7c 100644 (file)
@@ -4,7 +4,7 @@
 "               Mike Leary           <leary@nwlink.com>
 "               Markus Mottl         <markus.mottl@gmail.com>
 " URL:          http://www.ocaml.info/vim/indent/ocaml.vim
-" Last Change:  2013 Jun 29
+" Last Change:  2017 Jun 13
 "               2005 Jun 25 - Fixed multiple bugs due to 'else\nreturn ind' working
 "               2005 May 09 - Added an option to not indent OCaml-indents specially (MM)
 "               2013 June   - commented textwidth (Marc Weber)
@@ -101,7 +101,7 @@ function! GetOCamlIndent()
 
  " Return double 'shiftwidth' after lines matching:
  if lline =~ '^\s*|.*->\s*$'
-   return ind + &sw + &sw
+   return ind + 2 * shiftwidth()
  endif
 
  let line = getline(v:lnum)
@@ -172,7 +172,7 @@ function! GetOCamlIndent()
  " Indent if current line begins with 'and':
  elseif line =~ '^\s*and\>'
    if lline !~ '^\s*\(and\|let\|type\)\>\|\<end\s*$'
-     return ind - &sw
+     return ind - shiftwidth()
    endif
 
  " Indent if current line begins with 'with':
@@ -199,14 +199,14 @@ function! GetOCamlIndent()
  " or 'method':
  elseif line =~ '^\s*\(constraint\|inherit\|initializer\|method\)\>'
    if lline !~ s:obj
-     return indent(search('\<\(object\|object\s*(.*)\)\s*$', 'bW')) + &sw
+     return indent(search('\<\(object\|object\s*(.*)\)\s*$', 'bW')) + shiftwidth()
    endif
 
  endif
 
  " Add a 'shiftwidth' after lines ending with:
  if lline =~ '\(:\|=\|->\|<-\|(\|\[\|{\|{<\|\[|\|\[<\|\<\(begin\|do\|else\|fun\|function\|functor\|if\|initializer\|object\|parser\|private\|sig\|struct\|then\|try\)\|\<object\s*(.*)\)\s*$'
-   let ind = ind + &sw
+   let ind = ind + shiftwidth()
 
  " Back to normal indent after lines ending with ';;':
  elseif lline =~ ';;\s*$' && lline !~ '^\s*;;'
@@ -263,7 +263,7 @@ function! GetOCamlIndent()
 
  " Subtract a 'shiftwidth' after lines matching 'match ... with parser':
  if lline =~ '\<match\>.*\<with\>\s*\<parser\s*$'
-   let ind = ind - &sw
+   let ind = ind - shiftwidth()
  endif
 
  return ind
index bebb0528bb5f32cbebb10b7f342ba3d4dfc85de7..4acd42e3c84a25f61c35a13d32d5d450343e2d11 100644 (file)
@@ -131,7 +131,7 @@ function GetOccamIndent()
   if line =~ s:FirstLevelIndent || (line =~ s:FirstLevelNonColonEndIndent && line !~ s:ColonEnd)
        \ || (line !~ s:ColonStart && (prevline =~ s:SecondLevelIndent
        \ || (prevline =~ s:SecondLevelNonColonEndIndent && prevline !~ s:ColonEnd)))
-    let curindent = curindent + &shiftwidth
+    let curindent = curindent + shiftwidth()
 
     " Restore magic
     if !save_magic|setlocal nomagic|endif
@@ -153,7 +153,7 @@ function GetOccamIndent()
 
   while !found
 
-    if indent(prevlinenum) == curindent - &shiftwidth
+    if indent(prevlinenum) == curindent - shiftwidth()
       let found = 1
     endif
 
@@ -171,7 +171,7 @@ function GetOccamIndent()
 
   if prevlinenum > 0
     if getline(prevlinenum) =~ s:SecondLevelIndent
-      let curindent = curindent + &shiftwidth
+      let curindent = curindent + shiftwidth()
     endif
   endif
 
index 6dd3030e9c39a9e832504fc97983dfaf344a1b99..c7955d669b372cad830dfab0738054d0c5fd62b6 100644 (file)
@@ -2,7 +2,7 @@
 " Language:    Pascal
 " Maintainer:  Neil Carter <n.carter@swansea.ac.uk>
 " Created:     2004 Jul 13
-" Last Change: 2011 Apr 01
+" Last Change: 2017 Jun 13
 "
 " This is version 2.0, a complete rewrite.
 "
@@ -102,12 +102,12 @@ function! GetPascalIndent( line_num )
 
        " If the PREVIOUS LINE ended in these items, always indent
        if prev_codeline =~ '\<\(type\|const\|var\)$'
-               return indnt + &shiftwidth
+               return indnt + shiftwidth()
        endif
 
        if prev_codeline =~ '\<repeat$'
                if this_codeline !~ '^\s*until\>'
-                       return indnt + &shiftwidth
+                       return indnt + shiftwidth()
                else
                        return indnt
                endif
@@ -115,7 +115,7 @@ function! GetPascalIndent( line_num )
 
        if prev_codeline =~ '\<\(begin\|record\)$'
                if this_codeline !~ '^\s*end\>'
-                       return indnt + &shiftwidth
+                       return indnt + shiftwidth()
                else
                        return indnt
                endif
@@ -125,10 +125,10 @@ function! GetPascalIndent( line_num )
        " followed by "begin"
        if prev_codeline =~ '\<\(\|else\|then\|do\)$' || prev_codeline =~ ':$'
                if this_codeline !~ '^\s*begin\>'
-                       return indnt + &shiftwidth
+                       return indnt + shiftwidth()
                else
                        " If it does start with "begin" then keep the same indent
-                       "return indnt + &shiftwidth
+                       "return indnt + shiftwidth()
                        return indnt
                endif
        endif
@@ -137,7 +137,7 @@ function! GetPascalIndent( line_num )
        " only the line before the current one. TODO: Get it working for
        " parameter lists longer than two lines.
        if prev_codeline =~ '([^)]\+$'
-               return indnt + &shiftwidth
+               return indnt + shiftwidth()
        endif
 
 
@@ -146,7 +146,7 @@ function! GetPascalIndent( line_num )
        " Lines starting with "else", but not following line ending with
        " "end".
        if this_codeline =~ '^\s*else\>' && prev_codeline !~ '\<end$'
-               return indnt - &shiftwidth
+               return indnt - shiftwidth()
        endif
 
        " Lines after a single-statement branch/loop.
@@ -160,16 +160,16 @@ function! GetPascalIndent( line_num )
                " additional unindentation.
                if this_codeline =~ '^\s*\(end;\|except\|finally\|\)$'
                        " Note that we don't return from here.
-                       return indnt - &shiftwidth - &shiftwidth
+                       return indnt - 2 * shiftwidth()
                endif
-               return indnt - &shiftwidth
+               return indnt - shiftwidth()
        endif
 
        " Lines starting with "until" or "end". This rule must be overridden
        " by the one for "end" after a single-statement branch/loop. In
        " other words that rule should come before this one.
        if this_codeline =~ '^\s*\(end\|until\)\>'
-               return indnt - &shiftwidth
+               return indnt - shiftwidth()
        endif
 
 
@@ -201,7 +201,7 @@ function! GetPascalIndent( line_num )
 
        " If the PREVIOUS LINE ended in these items, always indent.
        if prev_codeline =~ '^\s*\(unit\|uses\|try\|except\|finally\|private\|protected\|public\|published\)$'
-               return indnt + &shiftwidth
+               return indnt + shiftwidth()
        endif
 
        " ???? Indent "procedure" and "functions" if they appear within an
@@ -212,11 +212,11 @@ function! GetPascalIndent( line_num )
        " UNINDENT ONCE
 
        if this_codeline =~ '^\s*\(except\|finally\)$'
-               return indnt - &shiftwidth
+               return indnt - shiftwidth()
        endif
 
        if this_codeline =~ '^\s*\(private\|protected\|public\|published\)$'
-               return indnt - &shiftwidth
+               return indnt - shiftwidth()
        endif
 
 
index fc4b6a30d3ef2f8e0e9214f676f0013548bbf870..cf256eae0adbaf36ef0abdd2f15b377eff04fcb2 100644 (file)
@@ -3,7 +3,7 @@
 " Maintainer:    vim-perl <vim-perl@googlegroups.com>
 " Homepage:      http://github.com/vim-perl/vim-perl
 " Bugs/requests: http://github.com/vim-perl/vim-perl/issues
-" Last Change:   2013-07-24
+" Last Change:   2017 Jun 13
 
 " Suggestions and improvements by :
 "   Aaron J. Sherman (use syntax for hints)
@@ -138,9 +138,9 @@ function! GetPerlIndent()
                         \ || synid =~ '^perl\(Sub\|Block\|Package\)Fold'
                 let brace = strpart(line, bracepos, 1)
                 if brace == '(' || brace == '{' || brace == '['
-                    let ind = ind + &sw
+                    let ind = ind + shiftwidth()
                 else
-                    let ind = ind - &sw
+                    let ind = ind - shiftwidth()
                 endif
             endif
             let bracepos = match(line, braceclass, bracepos + 1)
@@ -152,25 +152,25 @@ function! GetPerlIndent()
                         \ || synid == "perlMatchStartEnd"
                         \ || synid == "perlBraces"
                         \ || synid =~ '^perl\(Sub\|Block\|Package\)Fold'
-                let ind = ind - &sw
+                let ind = ind - shiftwidth()
             endif
         endif
     else
         if line =~ '[{[(]\s*\(#[^])}]*\)\=$'
-            let ind = ind + &sw
+            let ind = ind + shiftwidth()
         endif
         if cline =~ '^\s*[])}]'
-            let ind = ind - &sw
+            let ind = ind - shiftwidth()
         endif
     endif
 
     " Indent lines that begin with 'or' or 'and'
     if cline =~ '^\s*\(or\|and\)\>'
         if line !~ '^\s*\(or\|and\)\>'
-            let ind = ind + &sw
+            let ind = ind + shiftwidth()
         endif
     elseif line =~ '^\s*\(or\|and\)\>'
-        let ind = ind - &sw
+        let ind = ind - shiftwidth()
     endif
 
     return ind
index ff2a579f0a6b8ae0fd4b95c0cc7e9c68f7e635b1..8561c8c58c4545ac9629f78b1593c83eb3fb83e1 100644 (file)
@@ -3,7 +3,7 @@
 " Maintainer:    vim-perl <vim-perl@googlegroups.com>
 " Homepage:      http://github.com/vim-perl/vim-perl
 " Bugs/requests: http://github.com/vim-perl/vim-perl/issues
-" Last Change:   2013-07-21
+" Last Change:   2017 Jun 13
 " Contributors:  Andy Lester <andy@petdance.com>
 "                Hinrik Ã–rn Sigurðsson <hinrik.sig@gmail.com>
 "
@@ -107,19 +107,19 @@ function! GetPerl6Indent()
     endif
 
         if line =~ '[<«\[{(]\s*\(#[^)}\]»>]*\)\=$'
-            let ind = ind + &sw
+            let ind = ind + shiftwidth()
         endif
         if cline =~ '^\s*[)}\]»>]'
-            let ind = ind - &sw
+            let ind = ind - shiftwidth()
         endif
 
     " Indent lines that begin with 'or' or 'and'
     if cline =~ '^\s*\(or\|and\)\>'
         if line !~ '^\s*\(or\|and\)\>'
-            let ind = ind + &sw
+            let ind = ind + shiftwidth()
         endif
     elseif line =~ '^\s*\(or\|and\)\>'
-        let ind = ind - &sw
+        let ind = ind - shiftwidth()
     endif
 
     return ind
index 06b49f3cb675963a5db8e73ba19f2bf5b79f185a..35dddaa270788da16b0031845fc8bbf42fa7ea20 100644 (file)
@@ -3,7 +3,7 @@
 " Author:      John Wellesz <John.wellesz (AT) teaser (DOT) fr>
 " URL:         http://www.2072productions.com/vim/indent/php.vim
 " Home:                https://github.com/2072/PHP-Indenting-for-VIm
-" Last Change: 2017 March 12th
+" Last Change: 2017 Jun 13
 " Version:     1.62
 "
 "
@@ -50,25 +50,15 @@ let b:did_indent = 1
 
 let g:php_sync_method = 0
 
-if exists('*shiftwidth')
-  function! s:sw()
-    return shiftwidth()
-  endfunction
-else
-  function! s:sw()
-    return &shiftwidth
-  endfunction
-endif
-
 
 if exists("PHP_default_indenting")
-    let b:PHP_default_indenting = PHP_default_indenting * s:sw()
+    let b:PHP_default_indenting = PHP_default_indenting * shiftwidth()
 else
     let b:PHP_default_indenting = 0
 endif
 
 if exists("PHP_outdentSLComments")
-    let b:PHP_outdentSLComments = PHP_outdentSLComments * s:sw()
+    let b:PHP_outdentSLComments = PHP_outdentSLComments * shiftwidth()
 else
     let b:PHP_outdentSLComments = 0
 endif
@@ -357,7 +347,7 @@ function! FindTheSwitchIndent (lnum) " {{{
     let test = GetLastRealCodeLNum(a:lnum - 1)
 
     if test <= 1
-       return indent(1) - s:sw() * b:PHP_vintage_case_default_indent
+       return indent(1) - shiftwidth() * b:PHP_vintage_case_default_indent
     end
 
     while getline(test) =~ '^\s*}' && test > 1
@@ -371,7 +361,7 @@ function! FindTheSwitchIndent (lnum) " {{{
     if getline(test) =~# '^\s*switch\>'
        return indent(test)
     elseif getline(test) =~# s:defaultORcase
-       return indent(test) - s:sw() * b:PHP_vintage_case_default_indent
+       return indent(test) - shiftwidth() * b:PHP_vintage_case_default_indent
     else
        return FindTheSwitchIndent(test)
     endif
@@ -444,7 +434,7 @@ function! GetPhpIndent()
     endif
 
     if b:PHP_default_indenting
-       let b:PHP_default_indenting = g:PHP_default_indenting * s:sw()
+       let b:PHP_default_indenting = g:PHP_default_indenting * shiftwidth()
     endif
 
     let cline = getline(v:lnum)
@@ -701,7 +691,7 @@ function! GetPhpIndent()
        let b:PHP_CurrentIndentLevel = b:PHP_default_indenting
        return indent(FindTheIfOfAnElse(v:lnum, 1))
     elseif cline =~# s:defaultORcase
-       return FindTheSwitchIndent(v:lnum) + s:sw() * b:PHP_vintage_case_default_indent
+       return FindTheSwitchIndent(v:lnum) + shiftwidth() * b:PHP_vintage_case_default_indent
     elseif cline =~ '^\s*)\=\s*{'
        let previous_line = last_line
        let last_line_num = lnum
@@ -713,7 +703,7 @@ function! GetPhpIndent()
                let ind = indent(last_line_num)
 
                if  b:PHP_BracesAtCodeLevel
-                   let ind = ind + s:sw()
+                   let ind = ind + shiftwidth()
                endif
 
                return ind
@@ -724,7 +714,7 @@ function! GetPhpIndent()
        endwhile
 
     elseif last_line =~# unstated && cline !~ '^\s*);\='.endline
-       let ind = ind + s:sw() " we indent one level further when the preceding line is not stated
+       let ind = ind + shiftwidth() " we indent one level further when the preceding line is not stated
        return ind + addSpecial
 
     elseif (ind != b:PHP_default_indenting || last_line =~ '^[)\]]' ) && last_line =~ terminated
@@ -823,7 +813,7 @@ function! GetPhpIndent()
            endif
 
            if !dontIndent && (!b:PHP_BracesAtCodeLevel || last_line !~# '^\s*{')
-               let ind = ind + s:sw()
+               let ind = ind + shiftwidth()
            endif
 
            if b:PHP_BracesAtCodeLevel || b:PHP_vintage_case_default_indent == 1
@@ -841,17 +831,17 @@ function! GetPhpIndent()
            endif
 
        elseif last_line =~ '^\s*'.s:blockstart
-           let ind = ind + s:sw()
+           let ind = ind + shiftwidth()
 
 
        elseif AntepenultimateLine =~ '{'.endline && AntepenultimateLine !~? '^\s*use\>' || AntepenultimateLine =~ terminated || AntepenultimateLine =~# s:defaultORcase
-           let ind = ind + s:sw()
+           let ind = ind + shiftwidth()
        endif
 
     endif
 
     if cline =~  '^\s*[)\]];\='
-       let ind = ind - s:sw()
+       let ind = ind - shiftwidth()
     endif
 
     let b:PHP_CurrentIndentLevel = ind
index b0ff48e682420fde02109a458921e0cffcc0f3e0..2592bcf62fbdbbadda5cd144e0d8d1f5a05ec3d1 100644 (file)
@@ -41,16 +41,16 @@ function! PostscrIndentGet(lnum)
 
   " Indent for dicts, arrays, and saves with possible trailing comment
   if pline =~ '\(begin\|<<\|g\=save\|{\|[\)\s*\(%.*\)\=$'
-    let ind = ind + &sw
+    let ind = ind + shiftwidth()
   endif
 
   " Remove indent for popped dicts, and restores.
   if pline =~ '\(end\|g\=restore\)\s*$'
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
 
   " Else handle immediate dedents of dicts, restores, and arrays.
   elseif getline(a:lnum) =~ '\(end\|>>\|g\=restore\|}\|]\)'
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
 
   " Else handle DSC comments - always start of line.
   elseif getline(a:lnum) =~ '^\s*%%'
index 2b197635a1d89ec48101d9e9ac1103673e11e3c4..e806756c8e1a780e7ae4a4ec1b536b00387e66aa 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language: PoV-Ray Scene Description Language
 " Maintainer: David Necas (Yeti) <yeti@physics.muni.cz>
-" Last Change: 2002-10-20
+" Last Change: 2017 Jun 13
 " URI: http://trific.ath.cx/Ftp/vim/indent/pov.vim
 
 " Only load this indent file when no other was loaded.
@@ -75,9 +75,9 @@ function GetPoVRayIndent()
   " opening line.
   let cur = s:MatchCount(v:lnum, '^\s*\%(#\s*\%(end\|else\)\>\|[]})]\)')
   if cur > 0
-    let final = plind + (chg - cur) * &sw
+    let final = plind + (chg - cur) * shiftwidth()
   else
-    let final = plind + chg * &sw
+    let final = plind + chg * shiftwidth()
   endif
 
   return final < 0 ? 0 : final
index afe448e8f3e7a133ad3119afb4db4a6769a738e4..26a3bc3cd95e1ae52139ed910fea3a34e0df3e72 100644 (file)
@@ -41,18 +41,18 @@ function! GetPrologIndent()
     endif
     " Check for clause head on previous line
     if pline =~ ':-\s*\(%.*\)\?$'
-       let ind = ind + &sw
+       let ind = ind + shiftwidth()
     " Check for end of clause on previous line
     elseif pline =~ '\.\s*\(%.*\)\?$'
-       let ind = ind - &sw
+       let ind = ind - shiftwidth()
     endif
     " Check for opening conditional on previous line
     if pline =~ '^\s*\([(;]\|->\)'
-       let ind = ind + &sw
+       let ind = ind + shiftwidth()
     endif
     " Check for closing an unclosed paren, or middle ; or ->
     if line =~ '^\s*\([);]\|->\)'
-       let ind = ind - &sw
+       let ind = ind - shiftwidth()
     endif
     return ind
 endfunction
index 07bfd06590c9b36ee67da568908c6197774b5f8d..fab258ed2b9e56e28b335303fa241be4a4b25439 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:    RPL/2
 " Version:     0.2
-" Last Change: 2005 Mar 28
+" Last Change: 2017 Jun 13
 " Maintainer:  BERTRAND Joël <rpl2@free.fr>
 
 " Only load this indent file when no other was loaded.
@@ -32,16 +32,16 @@ function RplGetIndent(lnum)
   if prevstat =~? '\<\(if\|iferr\|do\|while\)\>' && prevstat =~? '\<end\>'
   elseif prevstat =~? '\(^\|\s\+\)<<\($\|\s\+\)' && prevstat =~? '\s\+>>\($\|\s\+\)'
   elseif prevstat =~? '\<\(if\|iferr\|then\|else\|elseif\|select\|case\|do\|until\|while\|repeat\|for\|start\|default\)\>' || prevstat =~? '\(^\|\s\+\)<<\($\|\s\+\)'
-    let ind = ind + &sw
+    let ind = ind + shiftwidth()
   endif
 
   " Subtract a shiftwidth from then, else, elseif, end, until, repeat, next,
   " step
   let line = getline(v:lnum)
   if line =~? '^\s*\(then\|else\|elseif\|until\|repeat\|next\|step\|default\|end\)\>'
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
   elseif line =~? '^\s*>>\($\|\s\+\)'
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
   endif
 
   return ind
index a97f4828d6cda70dc4a37302167856007b4bc1be..d8733db3055e04ac4546dc5d31188cbbf1be1f9b 100644 (file)
@@ -404,11 +404,7 @@ function GetRubyIndent(...)
   " ----------
 
   " The value of a single shift-width
-  if exists('*shiftwidth')
-    let sw = shiftwidth()
-  else
-    let sw = &sw
-  endif
+  let sw = shiftwidth()
 
   " For the current line, use the first argument if given, else v:lnum
   let clnum = a:0 ? a:1 : v:lnum
index a3051f0b0693d382296d5a844c329c40840fcb60..d30629b64e56c795f3d1118d3df2389e017f605d 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:         Rust
 " Author:           Chris Morgan <me@chrismorgan.info>
-" Last Change:      2017 Mar 21
+" Last Change:      2017 Jun 13
 " For bugs, patches and license go to https://github.com/rust-lang/rust.vim
 
 " Only load this indent file when no other was loaded.
@@ -199,7 +199,7 @@ function GetRustIndent(lnum)
                                        " It's the closing line, dedent it
                                        return 0
                                else
-                                       return &shiftwidth
+                                       return shiftwidth()
                                endif
                        endif
                endif
index d87b371fdd6bfb36d558e03e3840419d095fee16..d6dbf3a8bb67ccf2671f311120b8b483387d8ee4 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:    Sass
 " Maintainer:  Tim Pope <vimNOSPAM@tpope.org>
-" Last Change: 2016 Aug 29
+" Last Change: 2017 Jun 13
 
 if exists("b:did_indent")
   finish
@@ -29,7 +29,7 @@ function! GetSassIndent()
   let indent = indent(lnum)
   let cindent = indent(v:lnum)
   if line !~ s:property && line !~ s:extend && cline =~ s:property
-    return indent + (exists('*shiftwidth') ? shiftwidth() : &sw)
+    return indent + shiftwidth()
   else
     return -1
   endif
index ba03f2d3f482d27de592479f3166b40c358c29b0..6ce30b67978e0e961c7ec67e208d4402441ad3c6 100644 (file)
@@ -46,17 +46,17 @@ function! GetSDLIndent()
   if (getline(lnum) =~? '^\s*\(start\|state\|system\|package\|connection\|channel\|alternative\|macro\|operator\|newtype\|select\|substructure\|decision\|generator\|refinement\|service\|method\|exceptionhandler\|asntype\|syntype\|value\|(.*):\|\(priority\s\+\)\=input\|provided\)'
     \ || getline(lnum) =~? virtuality . '\(process\|procedure\|block\|object\)')
     \ && getline(lnum) !~? 'end[[:alpha:]]\+;$'
-    let ind = ind + &sw
+    let ind = ind + shiftwidth()
   endif
 
   " Subtract a 'shiftwidth' after states
   if getline(lnum) =~? '^\s*\(stop\|return\>\|nextstate\)'
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
   endif
 
   " Subtract a 'shiftwidth' on on end (uncompleted line)
   if getline(v:lnum) =~? '^\s*end\>'
-    let ind = ind - &sw
+    let ind = ind - shiftwidth()
   endif
 
   " Put each alternatives where the corresponding decision was
index fbbb15ed85fd5129801bf7b3f95d1473c58bec0a..e760a8e350f5651d51d2b0027d59b9d963323a5c 100644 (file)
@@ -115,9 +115,9 @@ function! GetSMLIndent()
 
        " Return double 'shiftwidth' after lines matching:
        if lline =~ '^\s*|.*=>\s*$'
-               return ind + &sw + &sw
+               return ind + 2 *shiftwidth()
        elseif lline =~ '^\s*val\>.*=\s*$'
-               return ind + &sw
+               return ind + shiftwidth()
        endif
 
   let line = getline(v:lnum)
@@ -157,7 +157,7 @@ function! GetSMLIndent()
                if lastModule == -1
                        return 0
                else
-                       return lastModule + &sw
+                       return lastModule + shiftwidth()
                endif
 
        " Indent lines starting with '|' from matching 'case', 'handle'
@@ -172,7 +172,7 @@ function! GetSMLIndent()
                if switchLine =~ '\<case\>'
                        return col(".") + 2
                elseif switchLine =~ '\<handle\>'
-                       return switchLineIndent + &sw
+                       return switchLineIndent + shiftwidth()
                elseif switchLine =~ '\<datatype\>'
                        call search('=')
                        return col(".") - 1
@@ -184,7 +184,7 @@ function! GetSMLIndent()
   " Indent if last line ends with 'sig', 'struct', 'let', 'then', 'else',
   " 'in'
   elseif lline =~ '\<\(sig\|struct\|let\|in\|then\|else\)\s*$'
-               let ind = ind + &sw
+               let ind = ind + shiftwidth()
 
   " Indent if last line ends with 'of', align from 'case'
   elseif lline =~ '\<\(of\)\s*$'
@@ -199,14 +199,14 @@ function! GetSMLIndent()
 
        " Indent if last line starts with 'fun', 'case', 'fn'
        elseif lline =~ '^\s*\(fun\|fn\|case\)\>'
-               let ind = ind + &sw
+               let ind = ind + shiftwidth()
 
        endif
 
        " Don't indent 'let' if last line started with 'fun', 'fn'
        if line =~ '^\s*let\>'
                if lline =~ '^\s*\(fun\|fn\)'
-                       let ind = ind - &sw
+                       let ind = ind - shiftwidth()
                endif
   endif
 
index d11c54b5affe2185d1dc34cdec7a0f089886c5f5..ba35d7671554ff0829890a27ccb923974c214de5 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:    SQL
 " Maintainer:  David Fishburn <dfishburn dot vim at gmail dot com>
-" Last Change: 2012 Dec 06
+" Last Change: 2017 Jun 13
 " Version:     3.0
 " Download:    http://vim.sourceforge.net/script.php?script_id=495
 
@@ -147,7 +147,7 @@ function! s:CheckToIgnoreRightParan( prev_lnum, num_levels )
     endwhile
 
     " Fallback - just move back one
-    " return a:prev_indent - &sw
+    " return a:prev_indent - shiftwidth()
     return ignore_paran
 endfunction
 
@@ -166,7 +166,7 @@ function! s:GetStmtStarterIndent( keyword, curr_lnum )
     let lnum  = a:curr_lnum
 
     " Default - reduce indent by 1
-    let ind = indent(a:curr_lnum) - &sw
+    let ind = indent(a:curr_lnum) - shiftwidth()
 
     if a:keyword =~? 'end'
         exec 'normal! ^'
@@ -230,7 +230,7 @@ function! s:ModuloIndent(ind)
     let ind = a:ind
 
     if ind > 0
-        let modulo = ind % &shiftwidth
+        let modulo = ind % shiftwidth()
 
         if modulo > 0
             let ind = ind - modulo
@@ -291,7 +291,7 @@ function! GetSQLIndent()
     " where END IF, END, should decrease the indent.
     if prevline =~? s:SQLBlockStart
         " Move indent in
-        let ind = ind + &sw
+        let ind = ind + shiftwidth()
         " echom 'prevl - SQLBlockStart - indent ' . ind . '  line: ' . prevline
     elseif prevline =~ '[()]'
         if prevline =~ '('
@@ -308,7 +308,7 @@ function! GetSQLIndent()
         if num_unmatched_left > 0
             " There is a open left paranethesis
             " increase indent
-            let ind = ind + ( &sw * num_unmatched_left )
+            let ind = ind + ( shiftwidth() * num_unmatched_left )
         elseif num_unmatched_right > 0
             " if it is an unbalanced paranethesis only unindent if
             " it was part of a command (ie create table(..)  )
@@ -323,7 +323,7 @@ function! GetSQLIndent()
             endif
 
             if (num_unmatched_right - ignore) > 0
-                let ind = ind - ( &sw * (num_unmatched_right - ignore) )
+                let ind = ind - ( shiftwidth() * (num_unmatched_right - ignore) )
             endif
 
         endif
@@ -339,12 +339,12 @@ function! GetSQLIndent()
     if line =~? '^\s*els'
         " Any line when you type else will automatically back up one
         " ident level  (ie else, elseif, elsif)
-        let ind = ind - &sw
+        let ind = ind - shiftwidth()
         " echom 'curr - else - indent ' . ind
     elseif line =~? '^\s*end\>'
         let ind = s:GetStmtStarterIndent('end', v:lnum)
         " General case for end
-        " let ind = ind - &sw
+        " let ind = ind - shiftwidth()
         " echom 'curr - end - indent ' . ind
     elseif line =~? '^\s*when\>'
         let ind = s:GetStmtStarterIndent('when', v:lnum)
@@ -352,7 +352,7 @@ function! GetSQLIndent()
         " clause, do not change the indent level, since these
         " statements do not have a corresponding END statement.
         " if stmt_starter =~? 'case'
-        "    let ind = ind - &sw
+        "    let ind = ind - shiftwidth()
         " endif
         " elseif line =~ '^\s*)\s*;\?\s*$'
         " elseif line =~ '^\s*)'
@@ -371,14 +371,14 @@ function! GetSQLIndent()
         " let num_unmatched_right  = s:CountUnbalancedParan( line, ')' )
         " if num_unmatched_right > 0
         " elseif strpart( line, strlen(line)-1, 1 ) =~ ')'
-        " let ind = ind - &sw
+        " let ind = ind - shiftwidth()
         if line =~ '^\s*)'
             " let ignore = ignore + 1
             " echom 'curr - begins ) unbalanced ignore: ' . ignore
         endif
 
         if (num_unmatched_right - ignore) > 0
-            let ind = ind - ( &sw * (num_unmatched_right - ignore) )
+            let ind = ind - ( shiftwidth() * (num_unmatched_right - ignore) )
         endif
         " endif
     endif
index b017535535f5b8a8284b9590e6c43961b48c3ee1..91fba4c3b673b18329e1d02c94297de0852c5bc8 100644 (file)
@@ -29,7 +29,7 @@ function SystemVerilogIndent()
   if exists('b:systemverilog_indent_width')
     let offset = b:systemverilog_indent_width
   else
-    let offset = &sw
+    let offset = shiftwidth()
   endif
   if exists('b:systemverilog_indent_modules')
     let indent_modules = offset
index 8467cefcc01fcad8c8c9d3bce8fecd30dbf8e1fe..370283c77f0ce80b31e64fede05af31e3952db68 100644 (file)
@@ -3,7 +3,7 @@
 "              Based on Tera Term Version 4.92
 " Maintainer:  Ken Takata
 " URL:         https://github.com/k-takata/vim-teraterm
-" Last Change: 2016 Aug 17
+" Last Change: 2017 Jun 13
 " Filenames:   *.ttl
 " License:     VIM License
 
@@ -22,16 +22,6 @@ if exists("*GetTeraTermIndent")
   finish
 endif
 
-" The shiftwidth() function is relatively new.
-" Don't require it to exist.
-if exists('*shiftwidth')
-  let s:sw = function('shiftwidth')
-else
-  function s:sw() abort
-    return &shiftwidth
-  endfunction
-endif
-
 function! GetTeraTermIndent(lnum)
   let l:prevlnum = prevnonblank(a:lnum-1)
   if l:prevlnum == 0
@@ -48,15 +38,15 @@ function! GetTeraTermIndent(lnum)
 
   if l:prevl =~ '^\s*if\>.*\<then\>'
     " previous line opened a block
-    let l:ind += s:sw()
+    let l:ind += shiftwidth()
   endif
   if l:prevl =~ '^\s*\%(elseif\|else\|do\|until\|while\|for\)\>'
     " previous line opened a block
-    let l:ind += s:sw()
+    let l:ind += shiftwidth()
   endif
   if l:thisl =~ '^\s*\%(elseif\|else\|endif\|enduntil\|endwhile\|loop\|next\)\>'
     " this line closed a block
-    let l:ind -= s:sw()
+    let l:ind -= shiftwidth()
   endif
 
   return l:ind
index fc6cc0a63882b43d4523aa995fd5f7c0eaa2e28d..1a4d8b1cb688fadac356052078f4c790d7c977d8 100644 (file)
@@ -215,14 +215,14 @@ function! GetTeXIndent() " {{{
     " ZYC modification : \end after \begin won't cause wrong indent anymore
     if line =~ '\\begin{.*}' 
         if line !~ g:tex_noindent_env
-            let ind = ind + &sw
+            let ind = ind + shiftwidth()
             let stay = 0
         endif
 
         if g:tex_indent_items
             " Add another sw for item-environments
             if line =~ g:tex_itemize_env
-                let ind = ind + &sw
+                let ind = ind + shiftwidth()
                 let stay = 0
             endif
         endif
@@ -241,23 +241,23 @@ function! GetTeXIndent() " {{{
         if g:tex_indent_items
             " Remove another sw for item-environments
             if cline =~ g:tex_itemize_env
-                let ind = ind - &sw
+                let ind = ind - shiftwidth()
                 let stay = 0
             endif
         endif
 
-        let ind = ind - &sw
+        let ind = ind - shiftwidth()
         let stay = 0
     endif
 
     if g:tex_indent_brace
         if line =~ '[[{]$'
-            let ind += &sw
+            let ind += shiftwidth()
             let stay = 0
         endif
 
         if cline =~ '^\s*\\\?[\]}]' && s:CheckPairedIsLastCharacter(v:lnum, indent(v:lnum))
-            let ind -= &sw
+            let ind -= shiftwidth()
             let stay = 0
         endif
 
@@ -266,7 +266,7 @@ function! GetTeXIndent() " {{{
                 let char = line[i]
                 if char == ']' || char == '}'
                     if s:CheckPairedIsLastCharacter(lnum, i)
-                        let ind -= &sw
+                        let ind -= shiftwidth()
                         let stay = 0
                     endif
                 endif
@@ -280,12 +280,12 @@ function! GetTeXIndent() " {{{
     if g:tex_indent_items
         " '\item' or '\bibitem' itself:
         if cline =~ g:tex_items
-            let ind = ind - &sw
+            let ind = ind - shiftwidth()
             let stay = 0
         endif
         " lines following to '\item' are intented once again:
         if line =~ g:tex_items
-            let ind = ind + &sw
+            let ind = ind + shiftwidth()
             let stay = 0
         endif
     endif
@@ -317,9 +317,9 @@ function! s:GetLastBeginIndentation(lnum) " {{{
                 return indent(lnum)
             endif
             if line =~ g:tex_itemize_env
-                return indent(lnum) + 2 * &sw
+                return indent(lnum) + 2 * shiftwidth()
             endif
-            return indent(lnum) + &sw
+            return indent(lnum) + shiftwidth()
         endif
     endfor
     return -1
@@ -347,7 +347,7 @@ function! s:GetEndIndentation(lnum) " {{{
             let min_indent = min([min_indent, indent(lnum)])
         endif
     endfor
-    return min_indent - &sw
+    return min_indent - shiftwidth()
 endfunction
 
 " Most of the code is from matchparen.vim
index 5fdcfe07117fceea61c6698c6a3763a381c6f1ed..13082c86925b29dfa192d48b0b0094317111c01f 100644 (file)
@@ -25,11 +25,11 @@ function GetTildeIndent(lnum)
        endif
 
        if getline(v:lnum) =~ '^\s*\~\(endif\|else\|elseif\|end\)\>'
-               return indent(v:lnum) - &sw
+               return indent(v:lnum) - shiftwidth()
        endif
 
        if getline(plnum) =~ '^\s*\~\(if\|foreach\|foreach_row\|xml_loop\|file_loop\|file_write\|file_append\|imap_loopsections\|imap_index\|imap_list\|ldap_search\|post_loopall\|post_loop\|file_loop\|sql_loop_num\|sql_dbmsselect\|search\|sql_loop\|post\|for\|function_define\|silent\|while\|setvalbig\|mail_create\|systempipe\|mail_send\|dual\|elseif\|else\)\>'
-               return indent(plnum) + &sw
+               return indent(plnum) + shiftwidth()
        else
                return -1
        endif
index 55a8ea302aee3d72de7b1b43f720ca7b1a8a4193..4d05345565b17498ad94ffb5243cff514385a434 100644 (file)
@@ -49,26 +49,26 @@ fun! VbGetIndent(lnum)
 
     " Add
     if previous_line =~? '^\s*\<\(begin\|\%(\%(private\|public\|friend\)\s\+\)\=\%(function\|sub\|property\)\|select\|case\|default\|if\|else\|elseif\|do\|for\|while\|enum\|with\)\>'
-       let ind = ind + &sw
+       let ind = ind + shiftwidth()
     endif
 
     " Subtract
     if this_line =~? '^\s*\<end\>\s\+\<select\>'
        if previous_line !~? '^\s*\<select\>'
-           let ind = ind - 2 * &sw
+           let ind = ind - 2 * shiftwidth()
        else
            " this case is for an empty 'select' -- 'end select'
            " (w/o any case statements) like:
            "
            " select case readwrite
            " end select
-           let ind = ind - &sw
+           let ind = ind - shiftwidth()
        endif
     elseif this_line =~? '^\s*\<\(end\|else\|elseif\|until\|loop\|next\|wend\)\>'
-       let ind = ind - &sw
+       let ind = ind - shiftwidth()
     elseif this_line =~? '^\s*\<\(case\|default\)\>'
        if previous_line !~? '^\s*\<select\>'
-           let ind = ind - &sw
+           let ind = ind - shiftwidth()
        endif
     endif
 
index 698285967011d5c6984ad529f8e02c8838f41d8c..7c3956035e9ca92ac8964725b8a4c380f644d44b 100644 (file)
@@ -2,7 +2,7 @@
 " Language:    VHDL
 " Maintainer:  Gerald Lai <laigera+vim?gmail.com>
 " Version:     1.60
-" Last Change: 2016 Feb 26
+" Last Change: 2017 Jun 13
 " URL:         http://www.vim.org/scripts/script.php?script_id=1450
 
 " only load this indent file when no other was loaded
@@ -114,9 +114,9 @@ function GetVHDLindent()
       return ind2 + m
     else
       if g:vhdl_indent_genportmap
-        return ind2 + stridx(prevs_noi, '(') + &sw
+        return ind2 + stridx(prevs_noi, '(') + shiftwidth()
       else
-        return ind2 + &sw
+        return ind2 + shiftwidth()
       endif
     endif
   endif
@@ -128,7 +128,7 @@ function GetVHDLindent()
     if g:vhdl_indent_rhsassign
       return ind2 + matchend(prevs_noi, '<=\s*\ze.')
     else
-      return ind2 + &sw
+      return ind2 + shiftwidth()
     endif
   endif
 
@@ -218,12 +218,12 @@ function GetVHDLindent()
       let ps = getline(pn)
 
       if (ps =~? s:NC.'\<begin\>')
-        return indent(pn) - &sw
+        return indent(pn) - shiftwidth()
       endif
     endwhile
 
     if (pn == 0)
-      return ind - &sw
+      return ind - shiftwidth()
     else
       return indent(pn)
     endif
@@ -237,7 +237,7 @@ function GetVHDLindent()
     " keyword: "type"
     let s3 = s:NC.s:NE.'\<type\>'
     if curs !~? s3.'.*'.s:NC.'\<\%(record\|units\)\>.*'.s:ES && prevs =~? s3
-      let ind = ind + &sw
+      let ind = ind + shiftwidth()
     endif
     return ind
   endif
@@ -282,7 +282,7 @@ function GetVHDLindent()
   " removed:  "begin", "case", "elsif", "if", "loop", "record", "units", "while"
   " where:    anywhere in previous line
   if prevs =~? s:NC.s:NE.'\<\%(block\|process\)\>'
-    return ind + &sw
+    return ind + shiftwidth()
   endif
 
   " indent:   +sw
@@ -290,7 +290,7 @@ function GetVHDLindent()
   " removed:  "component", "for", "when", "with"
   " where:    start of previous line
   if prevs =~? '^\s*\%(architecture\|configuration\|entity\|package\)\>'
-    return ind + &sw
+    return ind + shiftwidth()
   endif
 
   " indent:   +sw
@@ -298,7 +298,7 @@ function GetVHDLindent()
   " removed:  "generate", "is", "=>"
   " where:    end of previous line
   if prevs =~? s:NC.'\<select'.s:ES
-    return ind + &sw
+    return ind + shiftwidth()
   endif
 
   " indent:   +sw
@@ -310,7 +310,7 @@ function GetVHDLindent()
   " where:    end of previous line
   " _note_:   indent allowed to leave this filter
   if prevs =~? s:NC.'\%(\<begin\>\|'.s:NE.'\<\%(loop\|record\|units\)\>\)' || prevs =~? '^\s*\%(component\|else\|for\)\>' || prevs =~? s:NC.'\%('.s:NE.'\<generate\|\<\%(is\|then\)\|=>\)'.s:ES
-    let ind = ind + &sw
+    let ind = ind + shiftwidth()
   endif
 
   " ****************************************************************************************
@@ -322,7 +322,7 @@ function GetVHDLindent()
     if prevs =~? s:NC.'\<is'.s:ES
       return ind
     elseif prevs !~? s4
-      return ind - &sw
+      return ind - shiftwidth()
     else
       return ind2
     endif
@@ -336,7 +336,7 @@ function GetVHDLindent()
     if prevs =~? '^\s*\%(elsif\|'.s5.'\)'
       return ind
     else
-      return ind - &sw
+      return ind - shiftwidth()
     endif
   endif
 
@@ -367,9 +367,9 @@ function GetVHDLindent()
         "where:    start of previous non-comment line
         if m == 1
           if ps =~? '^\s*end\s\+case\>'
-            return indent(pn) - 2 * &sw
+            return indent(pn) - 2 * shiftwidth()
           elseif ps =~? '^\s*when\>'
-            return indent(pn) - &sw
+            return indent(pn) - shiftwidth()
           elseif ps =~? '^\s*case\>'
             return indent(pn)
           endif
@@ -385,14 +385,14 @@ function GetVHDLindent()
       let pn = prevnonblank(pn - 1)
       let ps = getline(pn)
     endwhile
-    return ind - &sw
+    return ind - shiftwidth()
   endif
 
   " indent:   -sw
   " keyword:  ")"
   " where:    start of current line
   if curs =~ '^\s*)'
-    return ind - &sw
+    return ind - shiftwidth()
   endif
 
   " indent:   0
@@ -407,7 +407,7 @@ function GetVHDLindent()
   " where:    start of current line
   "if curs =~? '^\s*end\s\+\w\+\>'
   if curs =~? '^\s*end\%(\s\|;'.s:ES.'\)'
-    return ind - &sw
+    return ind - shiftwidth()
   endif
 
   " ****************************************************************************************
index dbe5be5f251a7dd51f295c1285cc6ed8578b5ced..87ffb329b5d4ab68339f9fe7cd0e639ba32a2a05 100644 (file)
@@ -1,6 +1,6 @@
 " Language:    xml
 " Maintainer:  Johannes Zellner <johannes@zellner.org>
-" Last Change: 2012 Jul 25
+" Last Change: 2017 Jun 13
 " Notes:       1) does not indent pure non-xml code (e.g. embedded scripts)
 "              2) will be confused by unbalanced tags in comments
 "              or CDATA sections.
@@ -67,7 +67,7 @@ endfun
 fun! <SID>XmlIndentSum(lnum, style, add)
     let line = getline(a:lnum)
     if a:style == match(line, '^\s*</')
-       return (&sw *
+       return (shiftwidth() *
        \  (<SID>XmlIndentWithPattern(line, b:xml_indent_open)
        \ - <SID>XmlIndentWithPattern(line, b:xml_indent_close)
        \ - <SID>XmlIndentWithPattern(line, '.\{-}/>'))) + a:add
index 3201462fbc8067f7b0d9621e8f8baeeb1fbc028a..3eb16f845d83b4bee0aed3d74e6c03747e729505 100644 (file)
@@ -1,7 +1,7 @@
 " Vim indent file
 " Language:         YAML
 " Maintainer:       Nikolai Pavlov <zyx.vim@gmail.com>
-" Last Change:     2015 Nov 01
+" Last Change:     2017 Jun 13
 
 " Only load this indent file when no other was loaded.
 if exists('b:did_indent')
@@ -24,14 +24,6 @@ if exists('*GetYAMLIndent')
     finish
 endif
 
-if exists('*shiftwidth')
-    let s:shiftwidth = function('shiftwidth')
-else
-    function s:shiftwidth()
-        return &shiftwidth
-    endfunction
-endif
-
 function s:FindPrevLessIndentedLine(lnum, ...)
     let prevlnum = prevnonblank(a:lnum-1)
     let curindent = a:0 ? a:1 : indent(a:lnum)
@@ -119,7 +111,7 @@ function GetYAMLIndent(lnum)
         "
         " - |-
         "     Block scalar without indentation indicator
-        return previndent+s:shiftwidth()
+        return previndent+shiftwidth()
     elseif prevline =~# '\v[:-]\ [|>]%(\d+[+\-]?|[+\-]?\d+)%(\#.*|\s*)$'
         " - |+2
         "   block scalar with indentation indicator
@@ -155,7 +147,7 @@ function GetYAMLIndent(lnum)
                 \                             '\v)%(\s+|\s*%(\#.*)?$))*'
         " Mapping with: value
         "     that is multiline scalar
-        return previndent+s:shiftwidth()
+        return previndent+shiftwidth()
     endif
     return previndent
 endfunction
index eb02aaf4af50e6d3289db9ef6e9c7271ae656ee1..6e6ed1951a253cbf092bd61f28b39dc1f0a9cb6f 100644 (file)
@@ -3,7 +3,7 @@
 " Maintainer:  Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
 " Former Maintainers: Gerfried Fuchs <alfie@ist.org>
 "                     Wichert Akkerman <wakkerma@debian.org>
-" Last Change: 2016 Nov 12
+" Last Change: 2017 Apr 23
 " URL: https://anonscm.debian.org/cgit/pkg-vim/vim.git/plain/runtime/syntax/debchangelog.vim
 
 " Standard syntax initialization
@@ -14,14 +14,14 @@ endif
 " Case doesn't matter for us
 syn case ignore
 
-let urgency='urgency=\(low\|medium\|high\|critical\)\( [^[:space:],][^,]*\)\='
-let binNMU='binary-only=yes'
+let s:urgency='urgency=\(low\|medium\|high\|critical\)\( [^[:space:],][^,]*\)\='
+let s:binNMU='binary-only=yes'
 
 " Define some common expressions we can use later on
 syn match debchangelogName     contained "^[[:alnum:]][[:alnum:].+-]\+ "
-exe 'syn match debchangelogFirstKV     contained "; \('.urgency.'\|'.binNMU.'\)"'
-exe 'syn match debchangelogOtherKV     contained ", \('.urgency.'\|'.binNMU.'\)"'
-syn match debchangelogTarget   contained "\v %(frozen|unstable|sid|%(testing|%(old)=stable)%(-proposed-updates|-security)=|experimental|squeeze-%(backports%(-sloppy)=|volatile|lts|security)|wheezy-%(backports%(-sloppy)=|security)|jessie%(-backports|-security)=|stretch|%(devel|precise|trusty|vivid|wily|xenial|yakkety|zesty)%(-%(security|proposed|updates|backports|commercial|partner))=)+"
+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)%(-%(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\+\)*"
index 390c43035ec22c091ffb8cacdba9614cb8726355..4fa80debec19c0643d71bd610d3cb93fd0d88c1c 100644 (file)
@@ -2,7 +2,7 @@
 " Language:     Debian sources.list
 " Maintainer:   Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
 " Former Maintainer: Matthijs Mohlmann <matthijs@cacholong.nl>
-" Last Change: 2016 Nov 12
+" Last Change: 2017 Apr 22
 " URL: https://anonscm.debian.org/cgit/pkg-vim/vim.git/plain/runtime/syntax/debsources.vim
 
 " Standard syntax initialization
@@ -25,7 +25,7 @@ let s:supported = [
       \ 'oldstable', 'stable', 'testing', 'unstable', 'experimental',
       \ 'squeeze', 'wheezy', 'jessie', 'stretch', 'sid', 'rc-buggy',
       \
-      \ 'precise', 'trusty', 'xenial', 'yakkety', 'zesty', 'devel'
+      \ 'trusty', 'xenial', 'yakkety', 'zesty', 'artful', 'devel'
       \ ]
 let s:unsupported = [
       \ 'buzz', 'rex', 'bo', 'hamm', 'slink', 'potato',
@@ -33,15 +33,15 @@ let s:unsupported = [
       \
       \ 'warty', 'hoary', 'breezy', 'dapper', 'edgy', 'feisty',
       \ 'gutsy', 'hardy', 'intrepid', 'jaunty', 'karmic', 'lucid',
-      \ 'maverick', 'natty', 'oneiric', 'quantal', 'raring', 'saucy',
+      \ 'maverick', 'natty', 'oneiric', 'precise', 'quantal', 'raring', 'saucy',
       \ 'utopic', 'vivid', 'wily'
       \ ]
 let &cpo=s:cpo
 
 " Match uri's
 syn match debsourcesUri            +\(https\?://\|ftp://\|[rs]sh://\|debtorrent://\|\(cdrom\|copy\|file\):\)[^'        <>"]\++
-exe 'syn match debsourcesDistrKeyword   +\([[:alnum:]_./]*\)\('. join(s:supported, '\|'). '\)\([-[:alnum:]_./]*\)+'
-exe 'syn match debsourcesUnsupportedDistrKeyword +\([[:alnum:]_./]*\)\('. join(s:unsupported, '\|') .'\)\([-[:alnum:]_./]*\)+'
+exe 'syn match debsourcesDistrKeyword   +\([[:alnum:]_./]*\)\<\('. join(s:supported, '\|'). '\)\>\([-[:alnum:]_./]*\)+'
+exe 'syn match debsourcesUnsupportedDistrKeyword +\([[:alnum:]_./]*\)\<\('. join(s:unsupported, '\|') .'\)\>\([-[:alnum:]_./]*\)+'
 
 " Associate our matches and regions with pretty colours
 hi def link debsourcesLine                    Error
index 9f056eec6730bde3e3f0039d805c7b31f21351ec..70c4e65674c3a8a4f7a3968b1bb16bbc1324e8f8 100644 (file)
@@ -1,7 +1,7 @@
 " Vim syntax file
 " Language:    Vim help file
 " Maintainer:  Bram Moolenaar (Bram@vim.org)
-" Last Change: 2016 Sep 02
+" Last Change: 2017 Jun 13
 
 " Quit when a (custom) syntax file was already loaded
 if exists("b:current_syntax")
@@ -54,7 +54,8 @@ else
   syn match helpIgnore         "." contained
 endif
 syn keyword helpNote           note Note NOTE note: Note: NOTE: Notes Notes:
-syn keyword helpWarning                WARNING: Warning:
+syn keyword helpWarning                WARNING WARNING: Warning:
+syn keyword helpDeprecated     DEPRECATED DEPRECATED: Deprecated:
 syn match helpSpecial          "\<N\>"
 syn match helpSpecial          "\<N\.$"me=e-1
 syn match helpSpecial          "\<N\.\s"me=e-2
@@ -171,6 +172,7 @@ hi def link helpNotVi               Special
 hi def link helpSpecial                Special
 hi def link helpNote           Todo
 hi def link helpWarning                Todo
+hi def link helpDeprecated     Todo
 
 hi def link helpComment                Comment
 hi def link helpConstant       Constant
index 2fb08619fdef81948bd54863b370a7b3d6c4fefe..1108c3984d4c5f4bf53936d9274e67c5f4cb7b3e 100644 (file)
@@ -1,7 +1,7 @@
 " Vim syntax file
 " Language: php PHP 3/4/5/7
 " Maintainer: Jason Woofenden <jason@jasonwoof.com>
-" Last Change: Apr 28, 2017
+" Last Change: Jun 09, 2017
 " URL: https://jasonwoof.com/gitweb/?p=vim-syntax.git;a=blob;f=php.vim;hb=HEAD
 " Former Maintainers: Peter Hodge <toomuchphp-vim@yahoo.com>
 "         Debian VIM Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
@@ -197,7 +197,7 @@ syn keyword phpFunctions  nsapi_request_headers nsapi_response_headers nsapi_vir
 syn keyword phpFunctions  aggregate_info aggregate_methods_by_list aggregate_methods_by_regexp aggregate_methods aggregate_properties_by_list aggregate_properties_by_regexp aggregate_properties aggregate aggregation_info deaggregate  contained
 syn keyword phpFunctions  ocibindbyname ocicancel ocicloselob ocicollappend ocicollassign ocicollassignelem ocicollgetelem ocicollmax ocicollsize ocicolltrim ocicolumnisnull ocicolumnname ocicolumnprecision ocicolumnscale ocicolumnsize ocicolumntype ocicolumntyperaw ocicommit ocidefinebyname ocierror ociexecute ocifetch ocifetchinto ocifetchstatement ocifreecollection ocifreecursor ocifreedesc ocifreestatement ociinternaldebug ociloadlob ocilogoff ocilogon ocinewcollection ocinewcursor ocinewdescriptor ocinlogon ocinumcols ociparse ociplogon ociresult ocirollback ocirowcount ocisavelob ocisavelobfile ociserverversion ocisetprefetch ocistatementtype ociwritelobtofile ociwritetemporarylob contained
 syn keyword phpFunctions  odbc_autocommit odbc_binmode odbc_close_all odbc_close odbc_columnprivileges odbc_columns odbc_commit odbc_connect odbc_cursor odbc_data_source odbc_do odbc_error odbc_errormsg odbc_exec odbc_execute odbc_fetch_array odbc_fetch_into odbc_fetch_object odbc_fetch_row odbc_field_len odbc_field_name odbc_field_num odbc_field_precision odbc_field_scale odbc_field_type odbc_foreignkeys odbc_free_result odbc_gettypeinfo odbc_longreadlen odbc_next_result odbc_num_fields odbc_num_rows odbc_pconnect odbc_prepare odbc_primarykeys odbc_procedurecolumns odbc_procedures odbc_result_all odbc_result odbc_rollback odbc_setoption odbc_specialcolumns odbc_statistics odbc_tableprivileges odbc_tables  contained
-syn keyword phpFunctions  openssl_csr_export_to_file openssl_csr_export openssl_csr_new openssl_csr_sign openssl_error_string openssl_free_key openssl_get_privatekey openssl_get_publickey openssl_open openssl_pkcs7_decrypt openssl_pkcs7_encrypt openssl_pkcs7_sign openssl_pkcs7_verify openssl_pkey_export_to_file openssl_pkey_export openssl_pkey_get_private openssl_pkey_get_public openssl_pkey_new openssl_private_decrypt openssl_private_encrypt openssl_public_decrypt openssl_public_encrypt openssl_seal openssl_sign openssl_verify openssl_x509_check_private_key openssl_x509_checkpurpose openssl_x509_export_to_file openssl_x509_export openssl_x509_free openssl_x509_parse openssl_x509_read contained
+syn keyword phpFunctions  openssl_cipher_iv_length openssl_csr_export_to_file openssl_csr_export openssl_csr_get_public_key openssl_csr_get_subject openssl_csr_new openssl_csr_sign openssl_decrypt openssl_dh_compute_key openssl_digest openssl_encrypt openssl_error_string openssl_free_key openssl_get_cert_locations openssl_get_cipher_methods openssl_get_md_methods openssl_get_privatekey openssl_get_publickey openssl_open openssl_pbkdf2 openssl_pkcs12_export_to_file openssl_pkcs12_export openssl_pkcs12_read openssl_pkcs7_decrypt openssl_pkcs7_encrypt openssl_pkcs7_sign openssl_pkcs7_verify openssl_pkey_export_to_file openssl_pkey_export openssl_pkey_free openssl_pkey_get_details openssl_pkey_get_private openssl_pkey_get_public openssl_pkey_new openssl_private_decrypt openssl_private_encrypt openssl_public_decrypt openssl_public_encrypt openssl_random_pseudo_bytes openssl_seal openssl_sign openssl_spki_export_challenge openssl_spki_export openssl_spki_new openssl_spki_verify openssl_verify openssl_x509_check_private_key openssl_x509_checkpurpose openssl_x509_export_to_file openssl_x509_export openssl_x509_fingerprint openssl_x509_free openssl_x509_parse openssl_x509_read  contained
 syn keyword phpFunctions  ora_bind ora_close ora_columnname ora_columnsize ora_columntype ora_commit ora_commitoff ora_commiton ora_do ora_error ora_errorcode ora_exec ora_fetch_into ora_fetch ora_getcolumn ora_logoff ora_logon ora_numcols ora_numrows ora_open ora_parse ora_plogon ora_rollback  contained
 syn keyword phpFunctions  flush ob_clean ob_end_clean ob_end_flush ob_flush ob_get_clean ob_get_contents ob_get_flush ob_get_length ob_get_level ob_get_status ob_gzhandler ob_implicit_flush ob_list_handlers ob_start output_add_rewrite_var output_reset_rewrite_vars  contained
 syn keyword phpFunctions  overload  contained
index 2190047e0e61292508178bd12ab5f8a00101f72b..e348ba77469751742a0a02c675d1a33235094456 100644 (file)
@@ -11,7 +11,7 @@
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: vim 7.4\n"
+"Project-Id-Version: vim 8.0\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2017-05-28 10:54+0200\n"
 "PO-Revision-Date:  2017-05-28 23:45+0200\n"