diff --git a/autoload/neosnippet/util.vim b/autoload/neosnippet/util.vim index b494ec0..c4f92a3 100644 --- a/autoload/neosnippet/util.vim +++ b/autoload/neosnippet/util.vim @@ -1,7 +1,7 @@ "============================================================================= " FILE: util.vim " AUTHOR: Shougo Matsushita -" Last Modified: 23 Oct 2012. +" Last Modified: 17 Nov 2012. " License: MIT license {{{ " Permission is hereby granted, free of charge, to any person obtaining " a copy of this software and associated documentation files (the @@ -55,12 +55,8 @@ function! neosnippet#util#iconv(...)"{{{ endfunction"}}} function! neosnippet#util#expand(path)"{{{ - let path = (a:path =~ '^\~') ? - \ substitute(a:path, '^\~', expand('~'), '') : - \ (a:path =~ '^\$\h\w*') ? substitute(a:path, - \ '^\$\h\w*', '\=eval(submatch(0))', '') : - \ a:path - return s:V.substitute_path_separator(fnamemodify(path, ':p')) + return neosnippet#util#substitute_path_separator( + \ expand(escape(a:path, '*?[]"={}'), 1)) endfunction"}}} function! neosnippet#util#set_default(var, val, ...) "{{{ if !exists(a:var) || type({a:var}) != type(a:val)