diff options
author | Bram Moolenaar <Bram@vim.org> | 2018-06-12 17:03:39 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2018-06-12 17:03:39 +0200 |
commit | 19834010889fc5bfa0f88b3ba83133dae6c0a35d (patch) | |
tree | a6e4bda36d3989a0b143ef47204084e3d05c22d2 /src/ex_docmd.c | |
parent | 1c3c10492a291270fa89b3c8df11828792f927d3 (diff) |
patch 8.1.0047: no completion for :unlet $VARv8.1.0047
Problem: No completion for :unlet $VAR.
Solution: Add completion. (Jason Franklin)
Diffstat (limited to 'src/ex_docmd.c')
-rw-r--r-- | src/ex_docmd.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/ex_docmd.c b/src/ex_docmd.c index 3bc86f5ac8..5229e0e73b 100644 --- a/src/ex_docmd.c +++ b/src/ex_docmd.c @@ -4056,8 +4056,16 @@ set_one_cmd_context( case CMD_unlet: while ((xp->xp_pattern = vim_strchr(arg, ' ')) != NULL) arg = xp->xp_pattern + 1; + xp->xp_context = EXPAND_USER_VARS; xp->xp_pattern = arg; + + if (*xp->xp_pattern == '$') + { + xp->xp_context = EXPAND_ENV_VARS; + ++xp->xp_pattern; + } + break; case CMD_function: @@ -11277,7 +11285,10 @@ makeopens( * winminheight and winminwidth need to be set to avoid an error if the * user has set winheight or winwidth. */ - if (put_line(fd, "set winminheight=1 winheight=1 winminwidth=1 winwidth=1") == FAIL) + if (put_line(fd, "set winminheight=0") == FAIL + || put_line(fd, "set winheight=1") == FAIL + || put_line(fd, "set winminwidth=0") == FAIL + || put_line(fd, "set winwidth=1") == FAIL) return FAIL; if (nr > 1 && ses_winsizes(fd, restore_size, tab_firstwin) == FAIL) return FAIL; |