Hi, Bram
Occured in Vim 7.3.604 and later
reproduce
(1) :let foo=input('', '', 'dir')
(2) Hit escape key. (cancel input())
(3) :echo foo
displayed
dir
`dir` is 3rd argument value(the type of completion).
It's Not {cancelreturn} value.
Patch attatched. Please check.
Best regards,
--
Hirohito Higashi
--
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 6581d543a54c src/eval.c
--- a/src/eval.c Thu Aug 02 21:48:24 2012 +0200
+++ b/src/eval.c Mon Aug 06 00:37:03 2012 +0900
@@ -12966,7 +12966,7 @@
rettv->vval.v_string =
getcmdline_prompt(inputsecret_flag ? NUL : '@', p, echo_attr,
xp_type, xp_arg);
- if (rettv->vval.v_string == NULL
+ if (inputdialog && rettv->vval.v_string == NULL
&& argvars[1].v_type != VAR_UNKNOWN
&& argvars[2].v_type != VAR_UNKNOWN)
rettv->vval.v_string = vim_strsave(get_tv_string_buf(