- Improved partial match behavior.
This commit is contained in:
parent
c24924125b
commit
e367cd6330
@ -81,9 +81,17 @@ endfunction"}}}
|
|||||||
function! s:keyword_filter(snippets, cur_keyword_str)"{{{
|
function! s:keyword_filter(snippets, cur_keyword_str)"{{{
|
||||||
" Uniq by real_name.
|
" Uniq by real_name.
|
||||||
let dict = {}
|
let dict = {}
|
||||||
let list = filter(values(a:snippets),
|
|
||||||
\ printf('v:val.abbr =~ %s',
|
if len(a:cur_keyword_str) > 1
|
||||||
\ string(neocomplcache#keyword_escape(a:cur_keyword_str))))
|
" Use partial match by abbr.
|
||||||
|
let list = filter(values(a:snippets),
|
||||||
|
\ printf('v:val.abbr =~ %s',
|
||||||
|
\ string(neocomplcache#keyword_escape(a:cur_keyword_str))))
|
||||||
|
else
|
||||||
|
" Use default filter.
|
||||||
|
let list = neocomplcache#keyword_filter(
|
||||||
|
\ values(a:snippets), a:cur_keyword_str)
|
||||||
|
endif
|
||||||
|
|
||||||
" Add cur_keyword_str snippet.
|
" Add cur_keyword_str snippet.
|
||||||
if has_key(a:snippets, a:cur_keyword_str)
|
if has_key(a:snippets, a:cur_keyword_str)
|
||||||
|
@ -659,6 +659,7 @@ CHANGELOG *neosnippet-changelog*
|
|||||||
- Added g:neosnippet#enable_snipmate_compatibility option.
|
- Added g:neosnippet#enable_snipmate_compatibility option.
|
||||||
- Used partial match for neocomplcache completion.
|
- Used partial match for neocomplcache completion.
|
||||||
- Fixed for neocomplcache.
|
- Fixed for neocomplcache.
|
||||||
|
- Improved partial match behavior.
|
||||||
|
|
||||||
2012-11-01
|
2012-11-01
|
||||||
- Fixed snippet mirror behavior.
|
- Fixed snippet mirror behavior.
|
||||||
|
Loading…
Reference in New Issue
Block a user