diff options
author | naohiro ono <obcat@icloud.com> | 2021-08-19 21:20:41 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2021-08-19 21:20:41 +0200 |
commit | 5aec755b678cfd434b8ea2158d06992f33e1ff80 (patch) | |
tree | c9f19e9f5aed0047762772dedae8db831cfb7776 /src/evalfunc.c | |
parent | c66f645b809d0852592ca37afacb9031b5950c7f (diff) |
patch 8.2.3360: user function completion fails with dict functionv8.2.3360
Problem: User function completion fails with dict function.
Solution: Do not stop sequencing through the list if user functions when
encountering an empty name. (Naohiro Ono, closes #8765,
closes #8774)
Diffstat (limited to 'src/evalfunc.c')
-rw-r--r-- | src/evalfunc.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/evalfunc.c b/src/evalfunc.c index 4d73d40f12..d6fb03ee40 100644 --- a/src/evalfunc.c +++ b/src/evalfunc.c @@ -2307,9 +2307,10 @@ get_function_name(expand_T *xp, int idx) if (intidx < 0) { name = get_user_func_name(xp, idx); - if (name != NULL && *name != NUL) + if (name != NULL) { - if (*name != '<' && STRNCMP("g:", xp->xp_pattern, 2) == 0) + if (*name != NUL && *name != '<' + && STRNCMP("g:", xp->xp_pattern, 2) == 0) return cat_prefix_varname('g', name); return name; } |