summaryrefslogtreecommitdiffstats
path: root/src/ex_docmd.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2019-08-01 14:28:24 +0200
committerBram Moolenaar <Bram@vim.org>2019-08-01 14:28:24 +0200
commitb66bab381c8ba71fd6e92327d1d34c6f8a65f2a7 (patch)
tree0ce017c26ce910c3c0cf9aa02ddfb904fc319042 /src/ex_docmd.c
parent3f9bdeb2a521a408c04fd9584a752845b3accbbd (diff)
patch 8.1.1785: map functionality mixed with character inputv8.1.1785
Problem: Map functionality mixed with character input. Solution: Move the map functionality to a separate file. (Yegappan Lakshmanan, closes #4740) Graduate the +localmap feature.
Diffstat (limited to 'src/ex_docmd.c')
-rw-r--r--src/ex_docmd.c80
1 files changed, 0 insertions, 80 deletions
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index 1ddd28ffe5..514985633a 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -29,11 +29,6 @@ static void free_cmdmod(void);
static void append_command(char_u *cmd);
static char_u *find_command(exarg_T *eap, int *full);
-static void ex_abbreviate(exarg_T *eap);
-static void ex_map(exarg_T *eap);
-static void ex_unmap(exarg_T *eap);
-static void ex_mapclear(exarg_T *eap);
-static void ex_abclear(exarg_T *eap);
#ifndef FEAT_MENU
# define ex_emenu ex_ni
# define ex_menu ex_ni
@@ -231,7 +226,6 @@ static void ex_read(exarg_T *eap);
static void ex_pwd(exarg_T *eap);
static void ex_equal(exarg_T *eap);
static void ex_sleep(exarg_T *eap);
-static void do_exmap(exarg_T *eap, int isabbrev);
static void ex_winsize(exarg_T *eap);
static void ex_wincmd(exarg_T *eap);
#if defined(FEAT_GUI) || defined(UNIX) || defined(VMS) || defined(MSWIN)
@@ -5347,61 +5341,6 @@ getargopt(exarg_T *eap)
return OK;
}
-/*
- * ":abbreviate" and friends.
- */
- static void
-ex_abbreviate(exarg_T *eap)
-{
- do_exmap(eap, TRUE); /* almost the same as mapping */
-}
-
-/*
- * ":map" and friends.
- */
- static void
-ex_map(exarg_T *eap)
-{
- /*
- * If we are sourcing .exrc or .vimrc in current directory we
- * print the mappings for security reasons.
- */
- if (secure)
- {
- secure = 2;
- msg_outtrans(eap->cmd);
- msg_putchar('\n');
- }
- do_exmap(eap, FALSE);
-}
-
-/*
- * ":unmap" and friends.
- */
- static void
-ex_unmap(exarg_T *eap)
-{
- do_exmap(eap, FALSE);
-}
-
-/*
- * ":mapclear" and friends.
- */
- static void
-ex_mapclear(exarg_T *eap)
-{
- map_clear(eap->cmd, eap->arg, eap->forceit, FALSE);
-}
-
-/*
- * ":abclear" and friends.
- */
- static void
-ex_abclear(exarg_T *eap)
-{
- map_clear(eap->cmd, eap->arg, TRUE, TRUE);
-}
-
static void
ex_autocmd(exarg_T *eap)
{
@@ -7782,25 +7721,6 @@ do_sleep(long msec)
(void)vpeekc();
}
- static void
-do_exmap(exarg_T *eap, int isabbrev)
-{
- int mode;
- char_u *cmdp;
-
- cmdp = eap->cmd;
- mode = get_map_mode(&cmdp, eap->forceit || isabbrev);
-
- switch (do_map((*cmdp == 'n') ? 2 : (*cmdp == 'u'),
- eap->arg, mode, isabbrev))
- {
- case 1: emsg(_(e_invarg));
- break;
- case 2: emsg((isabbrev ? _(e_noabbr) : _(e_nomap)));
- break;
- }
-}
-
/*
* ":winsize" command (obsolete).
*/