summaryrefslogtreecommitdiff
path: root/src/ex_docmd.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-07-09 18:50:29 +0200
committerBram Moolenaar <Bram@vim.org>2016-07-09 18:50:29 +0200
commitaa4d73235bf4deee167aa5314b89ae3d3db334b7 (patch)
tree2ee78a96453d927a0408b23591f38976f34c7c8e /src/ex_docmd.c
parent537ef08408c50e0c4104d57f74993b3b0ed9560d (diff)
downloadvim-aa4d73235bf4deee167aa5314b89ae3d3db334b7.zip
patch 7.4.2011
Problem: It is not easy to get a list of command arguments. Solution: Add getcompletion(). (Yegappan Lakshmanan)
Diffstat (limited to 'src/ex_docmd.c')
-rw-r--r--src/ex_docmd.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index f8b50ed1d..07fdaa94a 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -7049,6 +7049,18 @@ parse_compl_arg(
# endif
return OK;
}
+
+ int
+cmdcomplete_str_to_type(char_u *complete_str)
+{
+ int i;
+
+ for (i = 0; command_complete[i].expand != 0; ++i)
+ if (STRCMP(complete_str, command_complete[i].name) == 0)
+ return command_complete[i].expand;
+
+ return EXPAND_NOTHING;
+}
#endif
static void