diff options
author | Bram Moolenaar <Bram@vim.org> | 2010-02-11 14:19:15 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2010-02-11 14:19:15 +0100 |
commit | 6dfc28be25dc1e4323b6652fa517e972007ff1bd (patch) | |
tree | ff19f5d6d935e56922bafdcab481d25d3ddbf759 /runtime/autoload | |
parent | cee6a352b23c8e444d4e0f4a219c288da1b19f76 (diff) | |
download | vim-git-6dfc28be25dc1e4323b6652fa517e972007ff1bd.tar.gz |
Updated runtime files.
Diffstat (limited to 'runtime/autoload')
-rw-r--r-- | runtime/autoload/syntaxcomplete.vim | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/runtime/autoload/syntaxcomplete.vim b/runtime/autoload/syntaxcomplete.vim index 91f5fab88..c887bd5a1 100644 --- a/runtime/autoload/syntaxcomplete.vim +++ b/runtime/autoload/syntaxcomplete.vim @@ -1,10 +1,15 @@ " Vim completion script " Language: All languages, uses existing syntax highlighting rules -" Maintainer: David Fishburn <dfishburn.vim@gmail.com> -" Version: 4.0 -" Last Change: Fri 26 Oct 2007 05:27:03 PM Eastern Daylight Time +" Maintainer: David Fishburn <dfishburn dot vim at gmail dot com> +" Version: 5.0 +" Last Change: 2010 Jan 31 " Usage: For detailed help, ":help ft-syntax-omni" +" History +" Version 5.0 +" When processing a list of syntax groups, the final group +" was missed in function SyntaxCSyntaxGroupItems. +" " Set completion with CTRL-X CTRL-O to autoloaded function. " This check is in place in case this script is " sourced directly instead of using the autoload feature. @@ -312,9 +317,13 @@ function! s:SyntaxCSyntaxGroupItems( group_name, syntax_full ) " \zs - start the match " .\{-} - everything ... " \ze - end the match + " \( - start a group or 2 potential matches " \n\w - at the first newline starting with a character + " \| - 2nd potential match + " \%$ - matches end of the file or string + " \) - end a group let syntax_group = matchstr(a:syntax_full, - \ "\n".a:group_name.'\s\+xxx\s\+\zs.\{-}\ze'."\n".'\w' + \ "\n".a:group_name.'\s\+xxx\s\+\zs.\{-}\ze\(\n\w\|\%$\)' \ ) if syntax_group != "" |