Hi, I found complete_check() doesn't check called from script behavior.

In complete_check() source code,

>int     saved = RedrawingDisabled;

>RedrawingDisabled = 0;
>ins_compl_check_keys(0);
>rettv->vval.v_number = compl_interrupted;
>RedrawingDisabled = saved;

complete_check() doesn't clear compl_interrupted when called from
other script(not from completefunc or omnifunc).
So I fixed this below patch.

-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
diff -r 5e84f6567623 -r 3f7d9e04dc76 src/eval.c
--- a/src/eval.c	Wed Sep 21 20:09:42 2011 +0200
+++ b/src/eval.c	Fri Sep 23 23:51:10 2011 +0900
@@ -9300,6 +9300,11 @@
 {
     int		saved = RedrawingDisabled;
 
+    if (using_script()) {
+        rettv->vval.v_number = FALSE;
+        return;
+    }
+
     RedrawingDisabled = 0;
     ins_compl_check_keys(0);
     rettv->vval.v_number = compl_interrupted;

Raspunde prin e-mail lui