Skip to content

Commit 89bcfda

Browse files
committed
Updated runtime files. Remove version checks for Vim older than 6.0.
1 parent 4792255 commit 89bcfda

427 files changed

Lines changed: 9968 additions & 13618 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

runtime/autoload/rubycomplete.vim

Lines changed: 32 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ function! s:GetBufferRubyEntity( name, type, ... )
9393

9494
let stopline = 1
9595

96-
let crex = '^\s*\<' . a:type . '\>\s*\<' . a:name . '\>\s*\(<\s*.*\s*\)\?'
96+
let crex = '^\s*\<' . a:type . '\>\s*\<' . escape(a:name, '*') . '\>\s*\(<\s*.*\s*\)\?'
9797
let [lnum,lcol] = searchpos( crex, 'w' )
9898
"let [lnum,lcol] = searchpairpos( crex . '\zs', '', '\(end\|}\)', 'w' )
9999

@@ -149,7 +149,7 @@ function! s:GetRubyVarType(v)
149149
let ctors = ctors.'\)'
150150

151151
let fstr = '=\s*\([^ \t]\+.' . ctors .'\>\|[\[{"''/]\|%[xwQqr][(\[{@]\|[A-Za-z0-9@:\-()\.]\+...\?\|lambda\|&\)'
152-
let sstr = ''.a:v.'\>\s*[+\-*/]*'.fstr
152+
let sstr = ''.escape(a:v, '*').'\>\s*[+\-*/]*'.fstr
153153
let [lnum,lcol] = searchpos(sstr,'nb',stopline)
154154
if lnum != 0 && lcol != 0
155155
let str = matchstr(getline(lnum),fstr,lcol)
@@ -266,6 +266,28 @@ class VimRubyCompletion
266266
end
267267
end
268268

269+
def load_gems
270+
fpath = VIM::evaluate("get(g:, 'rubycomplete_gemfile_path', 'Gemfile')")
271+
return unless File.file?(fpath) && File.readable?(fpath)
272+
want_bundler = VIM::evaluate("get(g:, 'rubycomplete_use_bundler')")
273+
parse_file = !want_bundler
274+
begin
275+
require 'bundler'
276+
Bundler.setup
277+
Bundler.require
278+
rescue Exception
279+
parse_file = true
280+
end
281+
if parse_file
282+
File.new(fpath).each_line do |line|
283+
begin
284+
require $1 if /\s*gem\s*['"]([^'"]+)/.match(line)
285+
rescue Exception
286+
end
287+
end
288+
end
289+
end
290+
269291
def load_buffer_class(name)
270292
dprint "load_buffer_class(%s) START" % name
271293
classdef = get_buffer_entity(name, 's:GetBufferRubyClass("%s")')
@@ -588,6 +610,10 @@ class VimRubyCompletion
588610
load_rails
589611
end
590612

613+
want_gems = VIM::evaluate("get(g:, 'rubycomplete_load_gemfile')")
614+
load_gems unless want_gems.to_i.zero?
615+
616+
591617
input = VIM::Buffer.current.line
592618
cpos = VIM::Window.current.cursor[1] - 1
593619
input = input[0..cpos]
@@ -678,7 +704,9 @@ class VimRubyCompletion
678704
cv = eval("self.class.constants")
679705
vartype = get_var_type( receiver )
680706
dprint "vartype: %s" % vartype
681-
if vartype != ''
707+
708+
invalid_vartype = ['', "gets"]
709+
if !invalid_vartype.include?(vartype)
682710
load_buffer_class( vartype )
683711

684712
begin
@@ -706,7 +734,7 @@ class VimRubyCompletion
706734
methods.concat m.instance_methods(false)
707735
}
708736
end
709-
variables += add_rails_columns( "#{vartype}" ) if vartype && vartype.length > 0
737+
variables += add_rails_columns( "#{vartype}" ) if vartype && !invalid_vartype.include?(vartype)
710738

711739
when /^\(?\s*[A-Za-z0-9:^@.%\/+*\(\)]+\.\.\.?[A-Za-z0-9:^@.%\/+*\(\)]+\s*\)?\.([^.]*)/
712740
message = $1

runtime/compiler/cucumber.vim

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
" Vim compiler file
22
" Compiler: Cucumber
33
" Maintainer: Tim Pope <[email protected]>
4-
" Last Change: 2010 Aug 09
4+
" Last Change: 2016 Aug 29
55

66
if exists("current_compiler")
77
finish
@@ -19,7 +19,7 @@ CompilerSet makeprg=cucumber
1919

2020
CompilerSet errorformat=
2121
\%W%m\ (Cucumber::Undefined),
22-
\%E%m\ (%.%#),
22+
\%E%m\ (%\\S%#),
2323
\%Z%f:%l,
2424
\%Z%f:%l:%.%#
2525

runtime/compiler/haml.vim

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
" Vim compiler file
22
" Compiler: Haml
33
" Maintainer: Tim Pope <[email protected]>
4-
" Last Change: 2013 May 30
4+
" Last Change: 2016 Aug 29
55

66
if exists("current_compiler")
77
finish
@@ -15,7 +15,7 @@ endif
1515
let s:cpo_save = &cpo
1616
set cpo-=C
1717

18-
CompilerSet makeprg=haml\ -c
18+
CompilerSet makeprg=haml
1919

2020
CompilerSet errorformat=
2121
\Haml\ %trror\ on\ line\ %l:\ %m,

runtime/compiler/rake.vim

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,11 @@ CompilerSet errorformat=
2727
\%\\s%#[%f:%l:\ %#%m,
2828
\%\\s%#%f:%l:\ %#%m,
2929
\%\\s%#%f:%l:,
30-
\%m\ [%f:%l]:
30+
\%m\ [%f:%l]:,
31+
\%+Erake\ aborted!,
32+
\%+EDon't\ know\ how\ to\ build\ task\ %.%#,
33+
\%+Einvalid\ option:%.%#,
34+
\%+Irake\ %\\S%\\+%\\s%\\+#\ %.%#
3135

3236
let &cpo = s:cpo_save
3337
unlet s:cpo_save

runtime/compiler/rspec.vim

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,10 @@ CompilerSet errorformat=
2222
\%f:%l:\ %tarning:\ %m,
2323
\%E%.%#:in\ `load':\ %f:%l:%m,
2424
\%E%f:%l:in\ `%*[^']':\ %m,
25-
\%-Z\ \ \ \ \ \#\ %f:%l:%.%#,
25+
\%-Z\ \ \ \ \ %\\+\#\ %f:%l:%.%#,
2626
\%E\ \ %\\d%\\+)%.%#,
2727
\%C\ \ \ \ \ %m,
28+
\%C%\\s%#,
2829
\%-G%.%#
2930

3031
let &cpo = s:cpo_save

runtime/compiler/rubyunit.vim

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ let s:cpo_save = &cpo
1717
set cpo-=C
1818

1919
CompilerSet makeprg=testrb
20+
" CompilerSet makeprg=ruby\ -Itest
21+
" CompilerSet makeprg=m
2022

2123
CompilerSet errorformat=\%W\ %\\+%\\d%\\+)\ Failure:,
2224
\%C%m\ [%f:%l]:,

runtime/compiler/sass.vim

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
" Vim compiler file
22
" Compiler: Sass
33
" Maintainer: Tim Pope <[email protected]>
4-
" Last Change: 2013 May 30
4+
" Last Change: 2016 Aug 29
55

66
if exists("current_compiler")
77
finish
@@ -15,7 +15,7 @@ endif
1515
let s:cpo_save = &cpo
1616
set cpo-=C
1717

18-
CompilerSet makeprg=sass\ -c
18+
CompilerSet makeprg=sass
1919

2020
CompilerSet errorformat=
2121
\%f:%l:%m\ (Sass::Syntax%trror),

runtime/defaults.vim

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ set ttimeoutlen=100 " wait up to 100ms after Esc for special key
3131
" Show @@@ in the last line if it is truncated.
3232
set display=truncate
3333

34-
" Show a few lines of context around the cursor.
34+
" Show a few lines of context around the cursor. Note that this makes the
35+
" text scroll if you mouse-click near the start or end of the window.
3536
set scrolloff=5
3637

3738
" Do incremental searching when it's possible to timeout.

runtime/doc/eval.txt

Lines changed: 18 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*eval.txt* For Vim version 7.4. Last change: 2016 Aug 29
1+
*eval.txt* For Vim version 7.4. Last change: 2016 Aug 30
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -643,13 +643,17 @@ It's possible to form a variable name with curly braces, see
643643

644644
Expression syntax summary, from least to most significant:
645645

646-
|expr1| expr2 ? expr1 : expr1 if-then-else
646+
|expr1| expr2
647+
expr2 ? expr1 : expr1 if-then-else
647648

648-
|expr2| expr3 || expr3 .. logical OR
649+
|expr2| expr3
650+
expr3 || expr3 .. logical OR
649651

650-
|expr3| expr4 && expr4 .. logical AND
652+
|expr3| expr4
653+
expr4 && expr4 .. logical AND
651654

652-
|expr4| expr5 == expr5 equal
655+
|expr4| expr5
656+
expr5 == expr5 equal
653657
expr5 != expr5 not equal
654658
expr5 > expr5 greater than
655659
expr5 >= expr5 greater than or equal
@@ -666,24 +670,28 @@ Expression syntax summary, from least to most significant:
666670
expr5 is expr5 same |List| instance
667671
expr5 isnot expr5 different |List| instance
668672

669-
|expr5| expr6 + expr6 .. number addition or list concatenation
673+
|expr5| expr6
674+
expr6 + expr6 .. number addition or list concatenation
670675
expr6 - expr6 .. number subtraction
671676
expr6 . expr6 .. string concatenation
672677

673-
|expr6| expr7 * expr7 .. number multiplication
678+
|expr6| expr7
679+
expr7 * expr7 .. number multiplication
674680
expr7 / expr7 .. number division
675681
expr7 % expr7 .. number modulo
676682

677-
|expr7| ! expr7 logical NOT
683+
|expr7| expr8
684+
! expr7 logical NOT
678685
- expr7 unary minus
679686
+ expr7 unary plus
680687

681-
|expr8| expr8[expr1] byte of a String or item of a |List|
688+
|expr8| expr9
689+
expr8[expr1] byte of a String or item of a |List|
682690
expr8[expr1 : expr1] substring of a String or sublist of a |List|
683691
expr8.name entry in a |Dictionary|
684692
expr8(expr1, ...) function call with |Funcref| variable
685693

686-
|expr9| number number constant
694+
|expr9| number number constant
687695
"string" string constant, backslash is special
688696
'string' string constant, ' is doubled
689697
[expr1, ...] |List|

runtime/doc/os_win32.txt

Lines changed: 3 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*os_win32.txt* For Vim version 7.4. Last change: 2016 Mar 05
1+
*os_win32.txt* For Vim version 7.4. Last change: 2016 Aug 28
22

33

44
VIM REFERENCE MANUAL by George Reilly
@@ -144,29 +144,8 @@ the console.
144144
5. Running under Windows 3.1 *win32-win3.1*
145145

146146
*win32s* *windows-3.1*
147-
There is a special version of Gvim that runs under Windows 3.1 and 3.11. You
148-
need the gvim.exe that was compiled with Visual C++ 4.1.
149-
150-
To run the Win32 version under Windows 3.1, you need to install Win32s. You
151-
might have it already from another Win32 application which you have installed.
152-
If Vim doesn't seem to be running properly, get the latest version: 1.30c.
153-
You can find it at:
154-
155-
http://support.microsoft.com/download/support/mslfiles/pw1118.exe
156-
157-
(Microsoft moved it again, we don't know where it is now :-( ).
158-
159-
The reason for having two versions of gvim.exe is that the Win32s version was
160-
compiled with VC++ 4.1. This is the last version of VC++ that supports Win32s
161-
programs. VC++ 5.0 is better, so that one was used for the Win32 version.
162-
Apart from that, there is no difference between the programs. If you are in a
163-
mixed environment, you can use the gvim.exe for Win32s on both.
164-
165-
The Win32s version works the same way as the Win32 version under 95/NT. When
166-
running under Win32s the following differences apply:
167-
- You cannot use long file names, because Windows 3.1 doesn't support them!
168-
- When executing an external command, it doesn't return an exit code. After
169-
doing ":make" you have to do ":cn" yourself.
147+
There was a special version of Gvim that runs under Windows 3.1 and 3.11.
148+
Support was removed in patch 7.4.1363.
170149

171150
==============================================================================
172151
6. Win32 mini FAQ *win32-faq*

0 commit comments

Comments
 (0)