From 179520e6907c5c0e5bf723236fccf250243316bb Mon Sep 17 00:00:00 2001 From: Miao Jiang Date: Thu, 17 Jan 2019 15:51:19 +0800 Subject: [PATCH] Fixes #229 triple quote stopped working --- plugin/auto-pairs.vim | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugin/auto-pairs.vim b/plugin/auto-pairs.vim index 3f0a911..7cd400f 100644 --- a/plugin/auto-pairs.vim +++ b/plugin/auto-pairs.vim @@ -211,6 +211,9 @@ func! AutoPairsInsert(key) " check open pairs let text=before.a:key for [open, close] in b:AutoPairsList + if open == close && open == "'" + let open = '\v(^|\W)\zs''' + end let m = s:matchend(text, open) if len(m) > 0 " process the open pair @@ -441,9 +444,6 @@ func! AutoPairsInit() " buffer level map pairs keys for [open, close] in items(b:AutoPairs) - if open == close && open == "'" - let open = '\v(^|\W)\zs''' - end let o = open[len(open)-1] let m = matchlist(close, '\v(.*)//(.*)$') let mapclose = 1