aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/cmdexpand.c
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2023-01-26 10:38:53 +0800
committerzeertzjq <zeertzjq@outlook.com>2023-01-26 11:55:34 +0800
commitf03f6263bb3eb0b28b759292cb6ef4465a05cafe (patch)
tree9529efa057f829a15d8fa4dc1c5ee54583f01463 /src/nvim/cmdexpand.c
parent6320c91c50e4c0ee5c366241f9a413c4edbfdad8 (diff)
downloadrneovim-f03f6263bb3eb0b28b759292cb6ef4465a05cafe.tar.gz
rneovim-f03f6263bb3eb0b28b759292cb6ef4465a05cafe.tar.bz2
rneovim-f03f6263bb3eb0b28b759292cb6ef4465a05cafe.zip
vim-patch:9.0.1238: :runtime completion can be further improved
Problem: :runtime completion can be further improved. Solution: Also complete the {where} argument values and adjust the completion for that. (closes vim/vim#11874) https://github.com/vim/vim/commit/5c8771bc5a2be123ab8e6325fa60ed524e8efb09
Diffstat (limited to 'src/nvim/cmdexpand.c')
-rw-r--r--src/nvim/cmdexpand.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/cmdexpand.c b/src/nvim/cmdexpand.c
index 21ea8c1ffc..53d513b319 100644
--- a/src/nvim/cmdexpand.c
+++ b/src/nvim/cmdexpand.c
@@ -2718,9 +2718,6 @@ static int ExpandFromContext(expand_T *xp, char *pat, char ***matches, int *numM
char *directories[] = { "colors", NULL };
return ExpandRTDir(pat, DIP_START + DIP_OPT, numMatches, matches, directories);
}
- if (xp->xp_context == EXPAND_RUNTIME) {
- return expand_runtime_cmd(pat, numMatches, matches);
- }
if (xp->xp_context == EXPAND_COMPILER) {
char *directories[] = { "compiler", NULL };
return ExpandRTDir(pat, 0, numMatches, matches, directories);
@@ -2742,6 +2739,9 @@ static int ExpandFromContext(expand_T *xp, char *pat, char ***matches, int *numM
if (xp->xp_context == EXPAND_PACKADD) {
return ExpandPackAddDir(pat, numMatches, matches);
}
+ if (xp->xp_context == EXPAND_RUNTIME) {
+ return expand_runtime_cmd(pat, numMatches, matches);
+ }
// When expanding a function name starting with s:, match the <SNR>nr_
// prefix.