diff options
Diffstat (limited to 'indent/clojure.vim')
-rw-r--r-- | indent/clojure.vim | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/indent/clojure.vim b/indent/clojure.vim index 7f79c9a2..c6069324 100644 --- a/indent/clojure.vim +++ b/indent/clojure.vim @@ -60,8 +60,7 @@ if exists("*searchpairpos") endfunction function! s:ignored_region() - let name = s:syn_id_name() - return (name =~? '\vstring|regex|comment|character') && (name !~# '^clojureCommentReaderMacro\(Form\)\?$') + return s:syn_id_name() =~? '\vstring|regex|comment|character' endfunction function! s:current_char() @@ -76,14 +75,10 @@ if exists("*searchpairpos") return s:current_char() =~# '\v[\(\)\[\]\{\}]' && !s:ignored_region() endfunction - " Returns 1 if string matches a pattern in 'patterns', which may be a - " list of patterns, or a comma-delimited string of implicitly anchored - " patterns. + " Returns 1 if string matches a pattern in 'patterns', which should be + " a list of patterns. function! s:match_one(patterns, string) - let list = type(a:patterns) == type([]) - \ ? a:patterns - \ : map(split(a:patterns, ','), '"^" . v:val . "$"') - for pat in list + for pat in a:patterns if a:string =~# pat | return 1 | endif endfor endfunction |