From 8e07c8de31d8d39611fa21af995f3ff0dfad62b9 Mon Sep 17 00:00:00 2001 From: Miao Jiang Date: Tue, 3 Sep 2013 16:39:44 +0800 Subject: [PATCH] Compatible with xmleditor. --- plugin/auto-pairs.vim | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plugin/auto-pairs.vim b/plugin/auto-pairs.vim index 94672a3..2a3bef7 100644 --- a/plugin/auto-pairs.vim +++ b/plugin/auto-pairs.vim @@ -498,7 +498,10 @@ function! AutoPairsTryInit() else let old_cr = s:ExpandMap(old_cr) " old_cr contain (, I guess the old cr is in expr mode - let is_expr = old_cr =~ '\V(' && toupper(old_cr) !~ '\V' + let is_expr = old_cr =~ '\V(' && toupper(old_cr) !~ '\V' + + " The old_cr start with " it must be in expr mode too + let is_expr = is_expr || old_cr =~ '\v^"' let wrapper_name = 'AutoPairsOldCRWrapper' end end