Fix TextChanged error

This commit is contained in:
Shougo Matsushita 2016-02-18 06:12:47 +09:00
parent bbd764ebbc
commit 0571ffbc47

View File

@ -57,8 +57,6 @@ function! s:initialize_others() abort "{{{
\ call neosnippet#variables#set_snippets({}) \ call neosnippet#variables#set_snippets({})
autocmd BufEnter * autocmd BufEnter *
\ call neosnippet#mappings#_clear_select_mode_mappings() \ call neosnippet#mappings#_clear_select_mode_mappings()
autocmd TextChanged,TextChangedI *
\ call neosnippet#handlers#_restore_unnamed_register()
augroup END"}}} augroup END"}}}
if g:neosnippet#enable_auto_clear_markers if g:neosnippet#enable_auto_clear_markers
@ -73,6 +71,11 @@ function! s:initialize_others() abort "{{{
\ call neosnippet#handlers#_complete_done() \ call neosnippet#handlers#_complete_done()
endif endif
if exists('##TextChanged') && exists('##TextChangedI')
autocmd neosnippet TextChanged,TextChangedI *
\ call neosnippet#handlers#_restore_unnamed_register()
endif
augroup neosnippet augroup neosnippet
autocmd BufNewFile,BufRead,Syntax * autocmd BufNewFile,BufRead,Syntax *
\ execute 'syntax match neosnippetExpandSnippets' \ execute 'syntax match neosnippetExpandSnippets'