diff options
Diffstat (limited to 'runtime')
| -rw-r--r-- | runtime/autoload/phpcomplete.vim | 181 | ||||
| -rw-r--r-- | runtime/doc/autocmd.txt | 2 | ||||
| -rw-r--r-- | runtime/doc/cmdline.txt | 9 | ||||
| -rw-r--r-- | runtime/doc/diff.txt | 7 | ||||
| -rw-r--r-- | runtime/doc/editing.txt | 4 | ||||
| -rw-r--r-- | runtime/doc/eval.txt | 30 | ||||
| -rw-r--r-- | runtime/doc/quickref.txt | 8 | ||||
| -rw-r--r-- | runtime/doc/syntax.txt | 3 | ||||
| -rw-r--r-- | runtime/filetype.vim | 3 | ||||
| -rw-r--r-- | runtime/indent/sh.vim | 4 | ||||
| -rw-r--r-- | runtime/indent/teraterm.vim | 67 | ||||
| -rw-r--r-- | runtime/optwin.vim | 6 | ||||
| -rw-r--r-- | runtime/syntax/python.vim | 89 | ||||
| -rw-r--r-- | runtime/syntax/teraterm.vim | 139 | ||||
| -rw-r--r-- | runtime/syntax/vb.vim | 2 | 
15 files changed, 435 insertions, 119 deletions
| diff --git a/runtime/autoload/phpcomplete.vim b/runtime/autoload/phpcomplete.vim index 6dcddfd43e..7f25d9df33 100644 --- a/runtime/autoload/phpcomplete.vim +++ b/runtime/autoload/phpcomplete.vim @@ -3,7 +3,7 @@  " Maintainer:	Dávid Szabó ( complex857 AT gmail DOT com )  " Previous Maintainer:	Mikolaj Machowski ( mikmach AT wp DOT pl )  " URL: https://github.com/shawncplus/phpcomplete.vim -" Last Change:  2015 Apr 02 +" Last Change:  2015 Jul 13  "  "	OPTIONS:  " @@ -318,7 +318,7 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{  					\ '^&\?\zs[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\ze')  		if f_name =~? '^'.substitute(a:base, '\\', '\\\\', 'g')  			let f_args = matchstr(i, -						\ '^&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\({\|$\)') +						\ '^&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\(;\|{\|$\)')  			let int_functions[f_name.'('] = f_args.')'  		endif  	endfor @@ -646,7 +646,7 @@ function! phpcomplete#CompleteUnknownClass(base, context) " {{{  		let f_name = matchstr(i,  				\ '^&\?\zs[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\ze')  		let f_args = matchstr(i, -				\ '^&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\({\|$\)') +				\ '^&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\(;\|{\|$\)')  		let int_functions[f_name.'('] = f_args.')'  	endfor @@ -981,7 +981,7 @@ function! phpcomplete#CompleteUserClass(context, base, sccontent, visibility) "  		let f_name = matchstr(i,  					\ 'function\s*&\?\zs[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\ze')  		let f_args = matchstr(i, -					\ 'function\s*&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\({\|\_$\)') +					\ 'function\s*&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\(;\|{\|\_$\)')  		if f_name != '' && stridx(f_name, '__') != 0  			let c_functions[f_name.'('] = f_args  			if g:phpcomplete_parse_docblock_comments @@ -1379,8 +1379,8 @@ function! phpcomplete#GetCallChainReturnType(classname_candidate, class_candidat  			" Get Structured information of all classes and subclasses including namespace and includes  			" try to find the method's return type in docblock comment  			for classstructure in classcontents -				let doclock_target_pattern = 'function\s\+&\?'.method.'\|\(public\|private\|protected\|var\).\+\$'.method -				let doc_str = phpcomplete#GetDocBlock(split(classstructure.content, '\n'), doclock_target_pattern) +				let docblock_target_pattern = 'function\s\+&\?'.method.'\|\(public\|private\|protected\|var\).\+\$'.method +				let doc_str = phpcomplete#GetDocBlock(split(classstructure.content, '\n'), docblock_target_pattern)  				if doc_str != ''  					break  				endif @@ -1659,7 +1659,7 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor  			" function declaration line  			if line =~? 'function\(\s\+'.function_name_pattern.'\)\?\s*(' -				let function_lines = join(reverse(lines), " ") +				let function_lines = join(reverse(copy(lines)), " ")  				" search for type hinted arguments  				if function_lines =~? 'function\(\s\+'.function_name_pattern.'\)\?\s*(.\{-}'.class_name_pattern.'\s\+'.object && !object_is_array  					let f_args = matchstr(function_lines, '\cfunction\(\s\+'.function_name_pattern.'\)\?\s*(\zs.\{-}\ze)') @@ -1700,10 +1700,12 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor  				" try to find the next non-comment or string ";" char  				let start_col = match(line, '^\s*'.object.'\C\s*=\zs&\?\s\+\(clone\)\?\s*'.variable_name_pattern) -				let filelines = reverse(lines) -				let [pos, char] = s:getNextCharWithPos(filelines, [a:start_line - i - 1, start_col]) +				let filelines = reverse(copy(lines)) +				let [pos, char] = s:getNextCharWithPos(filelines, [len(filelines) - i, start_col])  				let chars_read = 1  				let last_pos = pos +				" function_boundary == 0 if we are not in a function +				let real_lines_offset = len(function_boundary) == 1 ? 1 : function_boundary[0][0]  				" read while end of the file  				while char != 'EOF' && chars_read < 1000  					let last_pos = pos @@ -1711,7 +1713,11 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor  					let chars_read += 1  					" we got a candidate  					if char == ';' -						let synIDName = synIDattr(synID(pos[0] + 1, pos[1] + 1, 0), 'name') +						" pos values is relative to the function's lines, +						" line 0 need to be offsetted with the line number +						" where te function was started to get the line number +						" in real buffer terms +						let synIDName = synIDattr(synID(real_lines_offset + pos[0], pos[1] + 1, 0), 'name')  						" it's not a comment or string, end search  						if synIDName !~? 'comment\|string'  							break @@ -1719,7 +1725,7 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor  					endif  				endwhile -				let prev_context = phpcomplete#GetCurrentInstruction(last_pos[0] + 1, last_pos[1], b:phpbegin) +				let prev_context = phpcomplete#GetCurrentInstruction(real_lines_offset + last_pos[0], last_pos[1], b:phpbegin)  				if prev_context == ''  					" cannot get previous context give up  					return @@ -1739,13 +1745,14 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor  			" assignment for the variable in question with a function on the right hand side  			if line =~# '^\s*'.object.'\s*=&\?\s*'.function_invocation_pattern -  				" try to find the next non-comment or string ";" char  				let start_col = match(line, '\C^\s*'.object.'\s*=\zs&\?\s*'.function_invocation_pattern) -				let filelines = reverse(lines) -				let [pos, char] = s:getNextCharWithPos(filelines, [a:start_line - i - 1, start_col]) +				let filelines = reverse(copy(lines)) +				let [pos, char] = s:getNextCharWithPos(filelines, [len(filelines) - i, start_col])  				let chars_read = 1  				let last_pos = pos +				" function_boundary == 0 if we are not in a function +				let real_lines_offset = len(function_boundary) == 1 ? 1 : function_boundary[0][0]  				" read while end of the file  				while char != 'EOF' && chars_read < 1000  					let last_pos = pos @@ -1753,7 +1760,11 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor  					let chars_read += 1  					" we got a candidate  					if char == ';' -						let synIDName = synIDattr(synID(pos[0] + 1, pos[1] + 1, 0), 'name') +						" pos values is relative to the function's lines, +						" line 0 need to be offsetted with the line number +						" where te function was started to get the line number +						" in real buffer terms +						let synIDName = synIDattr(synID(real_lines_offset + pos[0], pos[1] + 1, 0), 'name')  						" it's not a comment or string, end search  						if synIDName !~? 'comment\|string'  							break @@ -1761,7 +1772,7 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor  					endif  				endwhile -				let prev_context = phpcomplete#GetCurrentInstruction(last_pos[0] + 1, last_pos[1], b:phpbegin) +				let prev_context = phpcomplete#GetCurrentInstruction(real_lines_offset + last_pos[0], last_pos[1], b:phpbegin)  				if prev_context == ''  					" cannot get previous context give up  					return @@ -1864,6 +1875,9 @@ function! phpcomplete#GetClassLocation(classname, namespace) " {{{  	if has_key(g:php_builtin_classes, tolower(a:classname)) && (a:namespace == '' || a:namespace == '\')  		return 'VIMPHP_BUILTINOBJECT'  	endif +	if has_key(g:php_builtin_interfaces, tolower(a:classname)) && (a:namespace == '' || a:namespace == '\') +		return 'VIMPHP_BUILTINOBJECT' +	endif  	if a:namespace == '' || a:namespace == '\'  		let search_namespace = '\' @@ -1876,7 +1890,7 @@ function! phpcomplete#GetClassLocation(classname, namespace) " {{{  	let i = 1  	while i < line('.')  		let line = getline(line('.')-i) -		if line =~? '^\s*\(abstract\s\+\|final\s\+\)*\s*\(class\|interface\|trait\)\s*'.a:classname.'\(\s\+\|$\)' && tolower(current_namespace) == search_namespace +		if line =~? '^\s*\(abstract\s\+\|final\s\+\)*\s*\(class\|interface\|trait\)\s*'.a:classname.'\(\s\+\|$\|{\)' && tolower(current_namespace) == search_namespace  			return expand('%:p')  		else  			let i += 1 @@ -2048,9 +2062,18 @@ function! phpcomplete#GetClassContentsStructure(file_path, file_lines, class_nam  	let content = join(getline(cfline, endline), "\n")  	" Catch extends  	if content =~? 'extends' -		let extends_class = matchstr(content, 'class\_s\+'.a:class_name.'\_s\+extends\_s\+\zs'.class_name_pattern.'\ze') +		let extends_string = matchstr(content, '\(class\|interface\)\_s\+'.a:class_name.'\_.\+extends\_s\+\zs\('.class_name_pattern.'\(,\|\_s\)*\)\+\ze\(extends\|{\)') +		let extended_classes = map(split(extends_string, '\(,\|\_s\)\+'), 'substitute(v:val, "\\_s\\+", "", "g")') +	else +		let extended_classes = '' +	endif + +	" Catch implements +	if content =~? 'implements' +		let implements_string = matchstr(content, 'class\_s\+'.a:class_name.'\_.\+implements\_s\+\zs\('.class_name_pattern.'\(,\|\_s\)*\)\+\ze') +		let implemented_interfaces = map(split(implements_string, '\(,\|\_s\)\+'), 'substitute(v:val, "\\_s\\+", "", "g")')  	else -		let extends_class = '' +		let implemented_interfaces = []  	endif  	call searchpair('{', '', '}', 'W')  	let class_closing_bracket_line = line('.') @@ -2108,8 +2131,11 @@ function! phpcomplete#GetClassContentsStructure(file_path, file_lines, class_nam  				\ })  	let all_extends = used_traits -	if extends_class != '' -		call add(all_extends, extends_class) +	if len(extended_classes) > 0 +		call extend(all_extends, extended_classes) +	endif +	if len(implemented_interfaces) > 0 +		call extend(all_extends, implemented_interfaces)  	endif  	if len(all_extends) > 0  		for class in all_extends @@ -2119,11 +2145,16 @@ function! phpcomplete#GetClassContentsStructure(file_path, file_lines, class_nam  			endif  			let classlocation = phpcomplete#GetClassLocation(class, namespace)  			if classlocation == "VIMPHP_BUILTINOBJECT" -				let result += [phpcomplete#GenerateBuiltinClassStub(g:php_builtin_classes[tolower(class)])] +				if has_key(g:php_builtin_classes, tolower(class)) +					let result += [phpcomplete#GenerateBuiltinClassStub('class', g:php_builtin_classes[tolower(class)])] +				endif +				if has_key(g:php_builtin_interfaces, tolower(class)) +					let result += [phpcomplete#GenerateBuiltinClassStub('interface', g:php_builtin_interfaces[tolower(class)])] +				endif  			elseif classlocation != '' && filereadable(classlocation)  				let full_file_path = fnamemodify(classlocation, ':p')  				let result += phpcomplete#GetClassContentsStructure(full_file_path, readfile(full_file_path), class) -			elseif tolower(current_namespace) == tolower(namespace) +			elseif tolower(current_namespace) == tolower(namespace) && match(join(a:file_lines, "\n"), '\c\(class\|interface\|trait\)\_s\+'.class.'\(\>\|$\)') != -1  				" try to find the declaration in the same file.  				let result += phpcomplete#GetClassContentsStructure(full_file_path, a:file_lines, class)  			endif @@ -2144,43 +2175,53 @@ function! phpcomplete#GetClassContents(classlocation, class_name) " {{{  endfunction  " }}} -function! phpcomplete#GenerateBuiltinClassStub(class_info) " {{{ -	let re = 'class '.a:class_info['name']." {" -	for [name, initializer] in items(a:class_info.constants) -		let re .= "\n\tconst ".name." = ".initializer.";" -	endfor -	for [name, info] in items(a:class_info.properties) -		let re .= "\n\t// @var $".name." ".info.type -		let re .= "\n\tpublic $".name.";" -	endfor -	for [name, info] in items(a:class_info.static_properties) -		let re .= "\n\t// @var ".name." ".info.type -		let re .= "\n\tpublic static ".name." = ".info.initializer.";" -	endfor -	for [name, info] in items(a:class_info.methods) -		if name =~ '^__' -			continue -		endif -		let re .= "\n\t/**" -		let re .= "\n\t * ".name -		let re .= "\n\t *" -		let re .= "\n\t * @return ".info.return_type -		let re .= "\n\t */" -		let re .= "\n\tpublic function ".name."(".info.signature."){" -		let re .= "\n\t}" -	endfor -	for [name, info] in items(a:class_info.static_methods) -		let re .= "\n\t/**" -		let re .= "\n\t * ".name -		let re .= "\n\t *" -		let re .= "\n\t * @return ".info.return_type -		let re .= "\n\t */" -		let re .= "\n\tpublic static function ".name."(".info.signature."){" -		let re .= "\n\t}" -	endfor +function! phpcomplete#GenerateBuiltinClassStub(type, class_info) " {{{ +	let re = a:type.' '.a:class_info['name']." {" +	if has_key(a:class_info, 'constants') +		for [name, initializer] in items(a:class_info.constants) +			let re .= "\n\tconst ".name." = ".initializer.";" +		endfor +	endif +	if has_key(a:class_info, 'properties') +		for [name, info] in items(a:class_info.properties) +			let re .= "\n\t// @var $".name." ".info.type +			let re .= "\n\tpublic $".name.";" +		endfor +	endif +	if has_key(a:class_info, 'static_properties') +		for [name, info] in items(a:class_info.static_properties) +			let re .= "\n\t// @var ".name." ".info.type +			let re .= "\n\tpublic static ".name." = ".info.initializer.";" +		endfor +	endif +	if has_key(a:class_info, 'methods') +		for [name, info] in items(a:class_info.methods) +			if name =~ '^__' +				continue +			endif +			let re .= "\n\t/**" +			let re .= "\n\t * ".name +			let re .= "\n\t *" +			let re .= "\n\t * @return ".info.return_type +			let re .= "\n\t */" +			let re .= "\n\tpublic function ".name."(".info.signature."){" +			let re .= "\n\t}" +		endfor +	endif +	if has_key(a:class_info, 'static_methods') +		for [name, info] in items(a:class_info.static_methods) +			let re .= "\n\t/**" +			let re .= "\n\t * ".name +			let re .= "\n\t *" +			let re .= "\n\t * @return ".info.return_type +			let re .= "\n\t */" +			let re .= "\n\tpublic static function ".name."(".info.signature."){" +			let re .= "\n\t}" +		endfor +	endif  	let re .= "\n}" -	return { 'class': a:class_info['name'], +	return { a:type : a:class_info['name'],  				\ 'content': re,  				\ 'namespace': '',  				\ 'imports': {}, @@ -2204,8 +2245,11 @@ function! phpcomplete#GetDocBlock(sccontent, search) " {{{  			" start backward serch for the comment block  			while l != 0  				let line = a:sccontent[l] -				" if comment end found save line position and end search -				if line =~? '^\s*\*/' +				" if it's a one line docblock like comment and we can just return it right away +				if line =~? '^\s*\/\*\*.\+\*\/\s*$' +					return substitute(line, '\v^\s*(\/\*\*\s*)|(\s*\*\/)\s*$', '', 'g') +				"... or if comment end found save line position and end search +				elseif line =~? '^\s*\*/'  					let comment_end = l  					break  				" ... or the line doesn't blank (only whitespace or nothing) end search @@ -2227,6 +2271,7 @@ function! phpcomplete#GetDocBlock(sccontent, search) " {{{  				endif  				let l -= 1  			endwhile +  			" no docblock comment start found  			if comment_start == -1  				return '' @@ -2388,7 +2433,15 @@ function! phpcomplete#GetCurrentNameSpace(file_lines) " {{{  			break  		endif  		let block_end_pos = searchpairpos('{', '', '}\|\%$', 'W', 'synIDattr(synID(line("."), col("."), 0), "name") =~? "string\\|comment"') -		silent! exec block_start_pos[0].','.block_end_pos[0].'d' + +		if block_end_pos != [0, 0] +			" end of the block found, just delete it +			silent! exec block_start_pos[0].','.block_end_pos[0].'d _' +		else +			" block pair not found, use block start as beginning and the end +			" of the buffer instead +			silent! exec block_start_pos[0].',$d _' +		endif  	endwhile  	normal! G @@ -2407,8 +2460,8 @@ function! phpcomplete#GetCurrentNameSpace(file_lines) " {{{  	while i < file_length  		let line = file_lines[i] -		if line =~? '^\s*namespace\s*'.namespace_name_pattern -			let current_namespace = matchstr(line, '\c^\s*namespace\s*\zs'.namespace_name_pattern.'\ze') +		if line =~? '^\(<?php\)\?\s*namespace\s*'.namespace_name_pattern +			let current_namespace = matchstr(line, '\c^\(<?php\)\?\s*namespace\s*\zs'.namespace_name_pattern.'\ze')  			break  		endif @@ -2571,7 +2624,7 @@ endfunction  function! phpcomplete#ExpandClassName(classname, current_namespace, imports) " {{{  	" if there's an imported class, just use that class's information -	if has_key(a:imports, a:classname) && (a:imports[a:classname].kind == 'c' || a:imports[a:classname].kind == 'i') +	if has_key(a:imports, a:classname) && (a:imports[a:classname].kind == 'c' || a:imports[a:classname].kind == 'i' || a:imports[a:classname].kind == 't')  		let namespace = has_key(a:imports[a:classname], 'namespace') ? a:imports[a:classname].namespace : ''  		return [a:imports[a:classname].name, namespace]  	endif diff --git a/runtime/doc/autocmd.txt b/runtime/doc/autocmd.txt index ec5818e16f..9f1b7702ed 100644 --- a/runtime/doc/autocmd.txt +++ b/runtime/doc/autocmd.txt @@ -1,4 +1,4 @@ -*autocmd.txt*   For Vim version 7.4.  Last change: 2015 Mar 21 +*autocmd.txt*   For Vim version 7.4.  Last change: 2015 Jul 20  		  VIM REFERENCE MANUAL    by Bram Moolenaar diff --git a/runtime/doc/cmdline.txt b/runtime/doc/cmdline.txt index ae808a4a9b..1236bc6e16 100644 --- a/runtime/doc/cmdline.txt +++ b/runtime/doc/cmdline.txt @@ -1,4 +1,4 @@ -*cmdline.txt*   For Vim version 7.4.  Last change: 2014 Sep 06 +*cmdline.txt*   For Vim version 7.4.  Last change: 2015 Jul 21  		  VIM REFERENCE MANUAL    by Bram Moolenaar @@ -565,6 +565,7 @@ starts editing the three files "foo bar", "goes to" and "school ".  When you want to use the special characters '"' or '|' in a command, or want  to use '%' or '#' in a file name, precede them with a backslash.  The  backslash is not required in a range and in the ":substitute" command. +See also |`=|.  							*:_!*  The '!' (bang) character after an Ex command makes the command behave in a @@ -715,7 +716,7 @@ example, "%" stands for the current file name, while CTRL-R % inserts the  current file name right away.  See |c_CTRL-R|.  Note: If you want to avoid the special characters in a Vim script you may want -to use |fnameescape()|. +to use |fnameescape()|.  Also see |`=|.  In Ex commands, at places where a file name can be used, the following @@ -755,7 +756,7 @@ it, no matter how many backslashes.  	   #			alternate.file  	   \#			#  	   \\#			\# - +Also see |`=|.  			       *:<cword>* *:<cWORD>* *:<cfile>* *<cfile>*  			       *:<sfile>* *<sfile>* *:<afile>* *<afile>*  			       *:<abuf>* *<abuf>* *:<amatch>* *<amatch>* @@ -910,6 +911,7 @@ Examples: (alternate file name is "?readme?")  	:e #.*		:e {files matching "?readme?.*"}  	:cd <cfile>	:cd {file name under cursor}  	:cd <cfile>*	:cd {file name under cursor plus "*" and then expanded} +Also see |`=|.  When the expanded argument contains a "!" and it is used for a shell command  (":!cmd", ":r !cmd" or ":w !cmd"), the "!" is escaped with a backslash to @@ -935,6 +937,7 @@ for the file "$home" in the root directory.  A few examples:  	\$home		file "$home" in current directory  	/\$home		file "$home" in root directory  	\\$home		file "\\", followed by expanded $home +Also see |`=|.  ==============================================================================  7. Command-line window				*cmdline-window* *cmdwin* diff --git a/runtime/doc/diff.txt b/runtime/doc/diff.txt index 8c9cdc3800..77603b1e58 100644 --- a/runtime/doc/diff.txt +++ b/runtime/doc/diff.txt @@ -1,4 +1,4 @@ -*diff.txt*      For Vim version 7.4.  Last change: 2015 Feb 03 +*diff.txt*      For Vim version 7.4.  Last change: 2015 Jul 03  		  VIM REFERENCE MANUAL    by Bram Moolenaar @@ -124,8 +124,9 @@ file for a moment and come back to the same file and be in diff mode again.  		if the current window does not have 'diff' set then no options  		in it are changed. -The ":diffoff" command resets the relevant options to the values they had when -using |:diffsplit|, |:diffpatch| , |:diffthis|. or starting Vim in diff mode. +The `:diffoff` command resets the relevant options to the values they had when +using `:diffsplit`, `:diffpatch` , `:diffthis`. or starting Vim in diff mode. +When using `:diffoff` twice the last saved values are restored.  Otherwise they are set to their default value:  	'diff'		off diff --git a/runtime/doc/editing.txt b/runtime/doc/editing.txt index bcb89f6527..507ee14baf 100644 --- a/runtime/doc/editing.txt +++ b/runtime/doc/editing.txt @@ -1,4 +1,4 @@ -*editing.txt*   For Vim version 7.4.  Last change: 2015 Apr 18 +*editing.txt*   For Vim version 7.4.  Last change: 2015 Jul 21  		  VIM REFERENCE MANUAL    by Bram Moolenaar @@ -397,6 +397,8 @@ does apply like to other wildcards.  If the expression returns a string then names are to be separated with line  breaks.  When the result is a |List| then each item is used as a name.  Line  breaks also separate names. +Note that such expressions are only supported in places where a filename is +expected as an argument to an Ex-command.  							*++opt* *[++opt]*  The [++opt] argument can be used to force the value of 'fileformat', diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index f3192e108b..6a1eac6814 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -1,4 +1,4 @@ -*eval.txt*	For Vim version 7.4.  Last change: 2015 Jun 26 +*eval.txt*	For Vim version 7.4.  Last change: 2015 Jul 21  		  VIM REFERENCE MANUAL	  by Bram Moolenaar @@ -1496,7 +1496,9 @@ v:hlsearch	Variable that indicates whether search highlighting is on.  		this variable to zero acts like the |:nohlsearch| command,  		setting it to one acts like >  			let &hlsearch = &hlsearch -< +<		Note that the value is restored when returning from a +		function. |function-search-undo|. +  					*v:insertmode* *insertmode-variable*  v:insertmode	Used for the |InsertEnter| and |InsertChange| autocommand  		events.  Values: @@ -4599,7 +4601,7 @@ match({expr}, {pat}[, {start}[, {count}]])			*match()*  		done like 'magic' is set and 'cpoptions' is empty.  					*matchadd()* *E798* *E799* *E801* -matchadd({group}, {pattern}[, {priority}[, {id}]]) +matchadd({group}, {pattern}[, {priority}[, {id} [, {dict}]]])  		Defines a pattern to be highlighted in the current window (a  		"match").  It will be highlighted with {group}.  Returns an  		identification number (ID), which can be used to delete the @@ -4607,6 +4609,8 @@ matchadd({group}, {pattern}[, {priority}[, {id}]])  		Matching is case sensitive and magic, unless case sensitivity  		or magicness are explicitly overridden in {pattern}.  The  		'magic', 'smartcase' and 'ignorecase' options are not used. +		The "Conceal" value is special, it causes the match to be +		concealed.  		The optional {priority} argument assigns a priority to the  		match.	A match with a high priority will have its @@ -5181,7 +5185,7 @@ readfile({fname} [, {binary} [, {max}]])  		separated with CR will result in a single long line (unless a  		NL appears somewhere).  		All NUL characters are replaced with a NL character. -		When {binary/append} contains "b" binary mode is used: +		When {binary} contains "b" binary mode is used:  		- When the last line ends in a NL an extra empty list item is  		  added.  		- No CR characters are removed. @@ -6205,6 +6209,24 @@ strchars({expr} [, {skipcc}])					*strchars()*  		When {skipcc} set to 1, Composing characters are ignored.  		Also see |strlen()|, |strdisplaywidth()| and |strwidth()|. +		 +		{skipcc} is only available after 7.4.755.  For backward +		compatibility, you can define a wrapper function: > +		    if has("patch-7.4.755") +		      function s:strchars(str, skipcc) +			return strchars(a:str, a:skipcc) +		      endfunction +		    else +		      function s:strchars(str, skipcc) +			if a:skipcc +			  return strlen(substitute(a:str, ".", "x", "g")) +			else +			  return strchars(a:str) +			endif +		      endfunction +		    endif +< +  strdisplaywidth({expr}[, {col}])			*strdisplaywidth()*  		The result is a Number, which is the number of display cells  		String {expr} occupies on the screen when it starts at {col}. diff --git a/runtime/doc/quickref.txt b/runtime/doc/quickref.txt index ded5e69438..120e027242 100644 --- a/runtime/doc/quickref.txt +++ b/runtime/doc/quickref.txt @@ -1,4 +1,4 @@ -*quickref.txt*  For Vim version 7.4.  Last change: 2014 Nov 19 +*quickref.txt*  For Vim version 7.4.  Last change: 2015 Jul 21  		  VIM REFERENCE MANUAL    by Bram Moolenaar @@ -617,6 +617,7 @@ Short explanation of each option:		*option-list*  'balloondelay'	  'bdlay'   delay in mS before a balloon may pop up  'ballooneval'	  'beval'   switch on balloon evaluation  'balloonexpr'	  'bexpr'   expression to show in balloon +'belloff'	  'bo'	    do not ring the bell for these reasons  'binary'	  'bin'     read/write/edit file in binary mode  'bomb'			    prepend a Byte Order Mark to the file  'breakat'	  'brk'     characters that may cause a line break @@ -688,6 +689,7 @@ Short explanation of each option:		*option-list*  'fileignorecase'  'fic'     ignore case when using file names  'filetype'	  'ft'	    type of file, used for autocommands  'fillchars'	  'fcs'     characters to use for displaying special items +'fixendofline'	  'fixeol'  make sure last line in file has <EOL>  'fkmap'		  'fk'	    Farsi keyboard mapping  'foldclose'	  'fcl'     close a fold when the cursor leaves it  'foldcolumn'	  'fdc'     width of the column used to indicate folds @@ -702,10 +704,10 @@ Short explanation of each option:		*option-list*  'foldnestmax'	  'fdn'     maximum fold depth  'foldopen'	  'fdo'     for which commands a fold will be opened  'foldtext'	  'fdt'     expression used to display for a closed fold +'formatexpr'	  'fex'     expression used with "gq" command  'formatlistpat'   'flp'     pattern used to recognize a list header  'formatoptions'   'fo'	    how automatic formatting is to be done  'formatprg'	  'fp'	    name of external program used with "gq" command -'formatexpr'	  'fex'     expression used with "gq" command  'fsync'		  'fs'	    whether to invoke fsync() after file write  'gdefault'	  'gd'	    the ":substitute" flag 'g' is default on  'grepformat'	  'gfm'     format of 'grepprg' output @@ -873,9 +875,9 @@ Short explanation of each option:		*option-list*  'switchbuf'	  'swb'     sets behavior when switching to another buffer  'synmaxcol'	  'smc'     maximum column to find syntax items  'syntax'	  'syn'     syntax to be loaded for current buffer -'tabstop'	  'ts'	    number of spaces that <Tab> in file uses  'tabline'	  'tal'     custom format for the console tab pages line  'tabpagemax'	  'tpm'     maximum number of tab pages for |-p| and "tab all" +'tabstop'	  'ts'	    number of spaces that <Tab> in file uses  'tagbsearch'	  'tbs'     use binary searching in tags files  'taglength'	  'tl'	    number of significant characters for a tag  'tagrelative'	  'tr'	    file names in tag file are relative diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index 6aed7441a0..d1c1f90c37 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1,4 +1,4 @@ -*syntax.txt*	For Vim version 7.4.  Last change: 2015 Mar 29 +*syntax.txt*	For Vim version 7.4.  Last change: 2015 Jul 21  		  VIM REFERENCE MANUAL	  by Bram Moolenaar @@ -3684,6 +3684,7 @@ Whether or not it is actually concealed depends on the value of the  'conceallevel' option.  The 'concealcursor' option is used to decide whether  concealable items in the current line are displayed unconcealed to be able to  edit the line. +Another way to conceal text with with |matchadd()|.  concealends						*:syn-concealends* diff --git a/runtime/filetype.vim b/runtime/filetype.vim index d60ab65ce7..15928d6722 100644 --- a/runtime/filetype.vim +++ b/runtime/filetype.vim @@ -2174,6 +2174,9 @@ au BufNewFile,BufRead *.tli			setf tli  " Telix Salt  au BufNewFile,BufRead *.slt			setf tsalt +" Tera Term Language +au BufRead,BufNewFile *.ttl			setf teraterm +  " Terminfo  au BufNewFile,BufRead *.ti			setf terminfo diff --git a/runtime/indent/sh.vim b/runtime/indent/sh.vim index 0394ee22e8..29a25a2108 100644 --- a/runtime/indent/sh.vim +++ b/runtime/indent/sh.vim @@ -1,6 +1,8 @@  " Vim indent file  " Language:         Shell Script -" Maintainer:       Peter Aronoff <telemachus@arpinum.org> +" Maintainer:       Currently unmaintained. If you want to take it, please +" 		    email Bram +" Previous Maintainer: Peter Aronoff <telemachus@arpinum.org>  " Original Author:  Nikolai Weibull <now@bitwi.se>  " Latest Revision:  2014-08-22 diff --git a/runtime/indent/teraterm.vim b/runtime/indent/teraterm.vim new file mode 100644 index 0000000000..ba24257b02 --- /dev/null +++ b/runtime/indent/teraterm.vim @@ -0,0 +1,67 @@ +" Vim indent file +" Language:	Tera Term Language (TTL) +"		Based on Tera Term Version 4.86 +" Maintainer:	Ken Takata +" URL:		https://github.com/k-takata/vim-teraterm +" Last Change:	2015 Jun 4 +" Filenames:	*.ttl +" License:	VIM License + +if exists("b:did_indent") +  finish +endif +let b:did_indent = 1 + +setlocal nosmartindent +setlocal noautoindent +setlocal indentexpr=GetTeraTermIndent(v:lnum) +setlocal indentkeys=!^F,o,O,e +setlocal indentkeys+==elseif,=endif,=loop,=next,=enduntil,=endwhile + +if exists("*GetTeraTermIndent") +  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! GetTeraTermIndent(lnum) +  let l:prevlnum = prevnonblank(a:lnum-1) +  if l:prevlnum == 0 +    " top of file +    return 0 +  endif + +  " grab the previous and current line, stripping comments. +  let l:prevl = substitute(getline(l:prevlnum), ';.*$', '', '') +  let l:thisl = substitute(getline(a:lnum), ';.*$', '', '') +  let l:previ = indent(l:prevlnum) + +  let l:ind = l:previ + +  if l:prevl =~ '^\s*if\>.*\<then\s*$' +    " previous line opened a block +    let l:ind += s:sw() +  endif +  if l:prevl =~ '^\s*\%(elseif\|else\|do\|until\|while\|for\)\>' +    " previous line opened a block +    let l:ind += s:sw() +  endif +  if l:thisl =~ '^\s*\%(elseif\|else\|endif\|enduntil\|endwhile\|loop\|next\)\>' +    " this line closed a block +    let l:ind -= s:sw() +  endif + +  return l:ind +endfunction + +" vim: ts=8 sw=2 sts=2 diff --git a/runtime/optwin.vim b/runtime/optwin.vim index a092f18d23..536c87ad7f 100644 --- a/runtime/optwin.vim +++ b/runtime/optwin.vim @@ -1,7 +1,7 @@  " These commands create the option window.  "  " Maintainer:	Bram Moolenaar <Bram@vim.org> -" Last Change:	2014 Nov 19 +" Last Change:	2015 Jul 22  " If there already is an option window, jump to that one.  if bufwinnr("option-window") > 0 @@ -673,6 +673,8 @@ call append("$", "errorbells\tring the bell for error messages")  call <SID>BinOptionG("eb", &eb)  call append("$", "visualbell\tuse a visual bell instead of beeping")  call <SID>BinOptionG("vb", &vb) +call append("$", "belloff\tdo not ring the bell for these reasons") +call <SID>OptionG("belloff", &belloff)  if has("multi_lang")    call append("$", "helplang\tlist of preferred languages for finding help")    call <SID>OptionG("hlg", &hlg) @@ -922,7 +924,7 @@ call <SID>BinOptionL("bin")  call append("$", "endofline\tlast line in the file has an end-of-line")  call append("$", "\t(local to buffer)")  call <SID>BinOptionL("eol") -call append("$", "fixeol\tfixes missing end-of-line at end of text file") +call append("$", "fixendofline\tfixes missing end-of-line at end of text file")  call append("$", "\t(local to buffer)")  call <SID>BinOptionL("fixeol")  if has("multi_byte") diff --git a/runtime/syntax/python.vim b/runtime/syntax/python.vim index c608aeedeb..f4369df131 100644 --- a/runtime/syntax/python.vim +++ b/runtime/syntax/python.vim @@ -1,7 +1,7 @@  " Vim syntax file  " Language:	Python  " Maintainer:	Zvezdan Petkovic <zpetkovic@acm.org> -" Last Change:	2015 Jun 19 +" Last Change:	2015 Jul 14  " Credits:	Neil Schemenauer <nas@python.ca>  "		Dmitry Vasiliev  " @@ -51,24 +51,25 @@ set cpo&vim  " Keep Python keywords in alphabetical order inside groups for easy  " comparison with the table in the 'Python Language Reference' -" http://docs.python.org/reference/lexical_analysis.html#keywords. +" https://docs.python.org/2/reference/lexical_analysis.html#keywords, +" https://docs.python.org/3/reference/lexical_analysis.html#keywords.  " Groups are in the order presented in NAMING CONVENTIONS in syntax.txt.  " Exceptions come last at the end of each group (class and def below).  "  " Keywords 'with' and 'as' are new in Python 2.6  " (use 'from __future__ import with_statement' in Python 2.5).  " -" Some compromises had to be made to support both Python 3.0 and 2.6. -" We include Python 3.0 features, but when a definition is duplicated, +" Some compromises had to be made to support both Python 3 and 2. +" We include Python 3 features, but when a definition is duplicated,  " the last definition takes precedence.  " -" - 'False', 'None', and 'True' are keywords in Python 3.0 but they are -"   built-ins in 2.6 and will be highlighted as built-ins below. -" - 'exec' is a built-in in Python 3.0 and will be highlighted as +" - 'False', 'None', and 'True' are keywords in Python 3 but they are +"   built-ins in 2 and will be highlighted as built-ins below. +" - 'exec' is a built-in in Python 3 and will be highlighted as  "   built-in below. -" - 'nonlocal' is a keyword in Python 3.0 and will be highlighted. -" - 'print' is a built-in in Python 3.0 and will be highlighted as -"   built-in below (use 'from __future__ import print_function' in 2.6) +" - 'nonlocal' is a keyword in Python 3 and will be highlighted. +" - 'print' is a built-in in Python 3 and will be highlighted as +"   built-in below (use 'from __future__ import print_function' in 2)  "  syn keyword pythonStatement	False, None, True  syn keyword pythonStatement	as assert break continue del exec global @@ -147,7 +148,8 @@ endif  " - 08e0 or 08j are highlighted,  "  " and so on, as specified in the 'Python Language Reference'. -" http://docs.python.org/reference/lexical_analysis.html#numeric-literals +" https://docs.python.org/2/reference/lexical_analysis.html#numeric-literals +" https://docs.python.org/3/reference/lexical_analysis.html#numeric-literals  if !exists("python_no_number_highlight")    " numbers (including longs and complex)    syn match   pythonNumber	"\<0[oO]\=\o\+[Ll]\=\>" @@ -159,54 +161,58 @@ if !exists("python_no_number_highlight")    syn match   pythonNumber  	\ "\<\d\+\.\%([eE][+-]\=\d\+\)\=[jJ]\=\%(\W\|$\)\@="    syn match   pythonNumber -	\ "\%(^\|\W\)\@<=\d*\.\d\+\%([eE][+-]\=\d\+\)\=[jJ]\=\>" +	\ "\%(^\|\W\)\zs\d*\.\d\+\%([eE][+-]\=\d\+\)\=[jJ]\=\>"  endif  " Group the built-ins in the order in the 'Python Library Reference' for  " easier comparison. -" http://docs.python.org/library/constants.html -" http://docs.python.org/library/functions.html -" http://docs.python.org/library/functions.html#non-essential-built-in-functions +" https://docs.python.org/2/library/constants.html +" https://docs.python.org/3/library/constants.html +" http://docs.python.org/2/library/functions.html +" http://docs.python.org/3/library/functions.html +" http://docs.python.org/2/library/functions.html#non-essential-built-in-functions +" http://docs.python.org/3/library/functions.html#non-essential-built-in-functions  " Python built-in functions are in alphabetical order.  if !exists("python_no_builtin_highlight")    " built-in constants -  " 'False', 'True', and 'None' are also reserved words in Python 3.0 +  " 'False', 'True', and 'None' are also reserved words in Python 3    syn keyword pythonBuiltin	False True None    syn keyword pythonBuiltin	NotImplemented Ellipsis __debug__    " built-in functions -  syn keyword pythonBuiltin	abs all any bin bool chr classmethod -  syn keyword pythonBuiltin	compile complex delattr dict dir divmod -  syn keyword pythonBuiltin	enumerate eval filter float format +  syn keyword pythonBuiltin	abs all any bin bool bytearray callable chr +  syn keyword pythonBuiltin	classmethod compile complex delattr dict dir +  syn keyword pythonBuiltin	divmod enumerate eval filter float format    syn keyword pythonBuiltin	frozenset getattr globals hasattr hash    syn keyword pythonBuiltin	help hex id input int isinstance    syn keyword pythonBuiltin	issubclass iter len list locals map max -  syn keyword pythonBuiltin	min next object oct open ord pow print -  syn keyword pythonBuiltin	property range repr reversed round set +  syn keyword pythonBuiltin	memoryview min next object oct open ord pow +  syn keyword pythonBuiltin	print property range repr reversed round set    syn keyword pythonBuiltin	setattr slice sorted staticmethod str    syn keyword pythonBuiltin	sum super tuple type vars zip __import__ -  " Python 2.6 only -  syn keyword pythonBuiltin	basestring callable cmp execfile file +  " Python 2 only +  syn keyword pythonBuiltin	basestring cmp execfile file    syn keyword pythonBuiltin	long raw_input reduce reload unichr    syn keyword pythonBuiltin	unicode xrange -  " Python 3.0 only -  syn keyword pythonBuiltin	ascii bytearray bytes exec memoryview -  " non-essential built-in functions; Python 2.6 only +  " Python 3 only +  syn keyword pythonBuiltin	ascii bytes exec +  " non-essential built-in functions; Python 2 only    syn keyword pythonBuiltin	apply buffer coerce intern  endif  " From the 'Python Library Reference' class hierarchy at the bottom. -" http://docs.python.org/library/exceptions.html +" http://docs.python.org/2/library/exceptions.html +" http://docs.python.org/3/library/exceptions.html  if !exists("python_no_exception_highlight") -  " builtin base exceptions (only used as base classes for other exceptions) +  " builtin base exceptions (used mostly as base classes for other exceptions)    syn keyword pythonExceptions	BaseException Exception -  syn keyword pythonExceptions	ArithmeticError EnvironmentError +  syn keyword pythonExceptions	ArithmeticError BufferError    syn keyword pythonExceptions	LookupError -  " builtin base exception removed in Python 3.0 -  syn keyword pythonExceptions	StandardError +  " builtin base exceptions removed in Python 3 +  syn keyword pythonExceptions	EnvironmentError StandardError    " builtin exceptions (actually raised) -  syn keyword pythonExceptions	AssertionError AttributeError BufferError +  syn keyword pythonExceptions	AssertionError AttributeError    syn keyword pythonExceptions	EOFError FloatingPointError GeneratorExit -  syn keyword pythonExceptions	IOError ImportError IndentationError +  syn keyword pythonExceptions	ImportError IndentationError    syn keyword pythonExceptions	IndexError KeyError KeyboardInterrupt    syn keyword pythonExceptions	MemoryError NameError NotImplementedError    syn keyword pythonExceptions	OSError OverflowError ReferenceError @@ -214,13 +220,26 @@ if !exists("python_no_exception_highlight")    syn keyword pythonExceptions	SystemError SystemExit TabError TypeError    syn keyword pythonExceptions	UnboundLocalError UnicodeError    syn keyword pythonExceptions	UnicodeDecodeError UnicodeEncodeError -  syn keyword pythonExceptions	UnicodeTranslateError ValueError VMSError -  syn keyword pythonExceptions	WindowsError ZeroDivisionError +  syn keyword pythonExceptions	UnicodeTranslateError ValueError +  syn keyword pythonExceptions	ZeroDivisionError +  " builtin OS exceptions in Python 3 +  syn keyword pythonExceptions	BlockingIOError BrokenPipeError +  syn keyword pythonExceptions	ChildProcessError ConnectionAbortedError +  syn keyword pythonExceptions	ConnectionError ConnectionRefusedError +  syn keyword pythonExceptions	ConnectionResetError FileExistsError +  syn keyword pythonExceptions	FileNotFoundError InterruptedError +  syn keyword pythonExceptions	IsADirectoryError NotADirectoryError +  syn keyword pythonExceptions	PermissionError ProcessLookupError +  syn keyword pythonExceptions	TimeoutError +  " builtin exceptions deprecated/removed in Python 3 +  syn keyword pythonExceptions	IOError VMSError WindowsError    " builtin warnings    syn keyword pythonExceptions	BytesWarning DeprecationWarning FutureWarning    syn keyword pythonExceptions	ImportWarning PendingDeprecationWarning    syn keyword pythonExceptions	RuntimeWarning SyntaxWarning UnicodeWarning    syn keyword pythonExceptions	UserWarning Warning +  " builtin warnings in Python 3 +  syn keyword pythonExceptions	ResourceWarning  endif  if exists("python_space_error_highlight") diff --git a/runtime/syntax/teraterm.vim b/runtime/syntax/teraterm.vim new file mode 100644 index 0000000000..521331d8ce --- /dev/null +++ b/runtime/syntax/teraterm.vim @@ -0,0 +1,139 @@ +" Vim syntax file +" Language:	Tera Term Language (TTL) +"		Based on Tera Term Version 4.86 +" Maintainer:	Ken Takata +" URL:		https://github.com/k-takata/vim-teraterm +" Last Change:	2015 Jun 24 +" Filenames:	*.ttl +" License:	VIM License + +if exists("b:current_syntax") +  finish +endif + +let s:save_cpo = &cpo +set cpo&vim + +syn case ignore + +syn region ttlComment	start=";" end="$" contains=@Spell +syn region ttlComment	start="/\*" end="\*/" contains=@Spell +syn region ttlFirstComment	start="/\*" end="\*/" contained contains=@Spell +			\ nextgroup=ttlStatement,ttlFirstComment + +syn match ttlCharacter	"#\%(\d\+\|\$\x\+\)\>" +syn match ttlNumber	"\%(\<\d\+\|\$\x\+\)\>" +syn match ttlString	"'[^']*'" contains=@Spell +syn match ttlString	'"[^"]*"' contains=@Spell +syn cluster ttlConstant contains=ttlCharacter,ttlNumber,ttlString + +syn match ttlLabel	":\s*\w\{1,32}\>" + +syn keyword ttlOperator	and or xor not + +syn match ttlVar	"\<groupmatchstr\d\>" +syn match ttlVar	"\<param\d\>" +syn keyword ttlVar	inputstr matchstr paramcnt result timeout mtimeout + + +syn match ttlLine nextgroup=ttlStatement "^" +syn match ttlStatement contained "\s*" +			\ nextgroup=ttlIf,ttlElseIf,ttlConditional,ttlRepeat, +			\ ttlFirstComment,ttlComment,ttlLabel,@ttlCommand + +syn cluster ttlCommand contains=ttlControlCommand,ttlCommunicationCommand, +			\ ttlStringCommand,ttlFileCommand,ttlPasswordCommand, +			\ ttlMiscCommand + + +syn keyword ttlIf contained nextgroup=ttlIfExpression if +syn keyword ttlElseIf contained nextgroup=ttlElseIfExpression elseif + +syn match ttlIfExpression contained "\s.*" +		\ contains=@ttlConstant,ttlVar,ttlOperator,ttlComment,ttlThen, +		\ @ttlCommand +syn match ttlElseIfExpression contained "\s.*" +		\ contains=@ttlConstant,ttlVar,ttlOperator,ttlComment,ttlThen + +syn keyword ttlThen contained then +syn keyword ttlConditional contained else endif + +syn keyword ttlRepeat contained for next until enduntil while endwhile +syn match ttlRepeat contained +			\ "\<\%(do\|loop\)\%(\s\+\%(while\|until\)\)\?\>" +syn keyword ttlControlCommand contained +			\ break call continue end execcmnd exit goto include +			\ mpause pause return + + +syn keyword ttlCommunicationCommand contained +			\ bplusrecv bplussend callmenu changedir clearscreen +			\ closett connect cygconnect disconnect dispstr +			\ enablekeyb flushrecv gethostname getmodemstatus +			\ gettitle kmtfinish kmtget kmtrecv kmtsend loadkeymap +			\ logautoclosemode logclose loginfo logopen logpause +			\ logrotate logstart logwrite quickvanrecv +			\ quickvansend recvln restoresetup scprecv scpsend +			\ send sendbreak sendbroadcast sendfile sendkcode +			\ sendln sendlnbroadcast sendmulticast setbaud +			\ setdebug setdtr setecho setmulticastname setrts +			\ setsync settitle showtt testlink unlink wait +			\ wait4all waitevent waitln waitn waitrecv waitregex +			\ xmodemrecv xmodemsend ymodemrecv ymodemsend +			\ zmodemrecv zmodemsend +syn keyword ttlStringCommand contained +			\ code2str expandenv int2str regexoption sprintf +			\ sprintf2 str2code str2int strcompare strconcat +			\ strcopy strinsert strjoin strlen strmatch strremove +			\ strreplace strscan strspecial strsplit strtrim +			\ tolower toupper +syn keyword ttlFileCommand contained +			\ basename dirname fileclose fileconcat filecopy +			\ filecreate filedelete filelock filemarkptr fileopen +			\ filereadln fileread filerename filesearch fileseek +			\ fileseekback filestat filestrseek filestrseek2 +			\ filetruncate fileunlock filewrite filewriteln +			\ findfirst findnext findclose foldercreate +			\ folderdelete foldersearch getdir getfileattr makepath +			\ setdir setfileattr +syn keyword ttlPasswordCommand contained +			\ delpassword getpassword ispassword passwordbox +			\ setpassword +syn keyword ttlMiscCommand contained +			\ beep bringupbox checksum8 checksum8file checksum16 +			\ checksum16file checksum32 checksum32file closesbox +			\ clipb2var crc16 crc16file crc32 crc32file exec +			\ dirnamebox filenamebox getdate getenv getipv4addr +			\ getipv6addr getspecialfolder gettime getttdir getver +			\ ifdefined inputbox intdim listbox messagebox random +			\ rotateleft rotateright setdate setdlgpos setenv +			\ setexitcode settime show statusbox strdim uptime +			\ var2clipb yesnobox + + +hi def link ttlCharacter Character +hi def link ttlNumber Number +hi def link ttlComment Comment +hi def link ttlFirstComment Comment +hi def link ttlString String +hi def link ttlLabel Label +hi def link ttlIf Conditional +hi def link ttlElseIf Conditional +hi def link ttlThen Conditional +hi def link ttlConditional Conditional +hi def link ttlRepeat Repeat +hi def link ttlControlCommand Keyword +hi def link ttlVar Identifier +hi def link ttlOperator Operator +hi def link ttlCommunicationCommand Keyword +hi def link ttlStringCommand Keyword +hi def link ttlFileCommand Keyword +hi def link ttlPasswordCommand Keyword +hi def link ttlMiscCommand Keyword + +let b:current_syntax = "teraterm" + +let &cpo = s:save_cpo +unlet s:save_cpo + +" vim: ts=8 sw=2 sts=2 diff --git a/runtime/syntax/vb.vim b/runtime/syntax/vb.vim index 14f9e64850..0c05b35fbd 100644 --- a/runtime/syntax/vb.vim +++ b/runtime/syntax/vb.vim @@ -223,7 +223,7 @@ syn keyword vbStatement Explicit FileCopy For ForEach Function Get GoSub  syn keyword vbStatement GoTo Gosub Implements Kill LSet Let Lib LineInput  syn keyword vbStatement Load Lock Loop Mid MkDir Name Next On OnError Open  syn keyword vbStatement Option Preserve Private Property Public Put RSet -syn keyword vbStatement RaiseEvent Randomize ReDim Redim Rem Reset Resume +syn keyword vbStatement RaiseEvent Randomize ReDim Redim Reset Resume  syn keyword vbStatement Return RmDir SavePicture SaveSetting Seek SendKeys  syn keyword vbStatement Sendkeys Set SetAttr Static Step Stop Sub Time  syn keyword vbStatement Type Unload Unlock Until Wend While Width With | 
