summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/charset.c5
-rw-r--r--src/eval.c8
-rw-r--r--src/ex_cmds.c6
-rw-r--r--src/ex_cmds2.c6
-rw-r--r--src/ex_docmd.c19
-rw-r--r--src/ex_getln.c5
-rw-r--r--src/feature.h7
-rw-r--r--src/getchar.c29
-rw-r--r--src/globals.h4
-rw-r--r--src/normal.c6
-rw-r--r--src/ui.c5
-rw-r--r--src/version.c6
12 files changed, 12 insertions, 94 deletions
diff --git a/src/charset.c b/src/charset.c
index 538d82115..2414b2a40 100644
--- a/src/charset.c
+++ b/src/charset.c
@@ -822,14 +822,11 @@ vim_strnsize(char_u *s, int len)
else \
return ptr2cells(p);
-#if defined(FEAT_VREPLACE) || defined(FEAT_EX_EXTRA) || defined(FEAT_GUI) \
- || defined(FEAT_VIRTUALEDIT) || defined(PROTO)
int
chartabsize(char_u *p, colnr_T col)
{
RET_WIN_BUF_CHARTABSIZE(curwin, curbuf, p, col)
}
-#endif
#ifdef FEAT_LINEBREAK
static int
@@ -1568,7 +1565,6 @@ skiphex(char_u *q)
}
#endif
-#if defined(FEAT_EX_EXTRA) || defined(PROTO)
/*
* skip to bin digit (or NUL after the string)
*/
@@ -1607,7 +1603,6 @@ skiptohex(char_u *q)
++p;
return p;
}
-#endif
/*
* Variant of isdigit() that can handle characters > 0x100.
diff --git a/src/eval.c b/src/eval.c
index 767925193..d2ebeb971 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -12855,9 +12855,7 @@ f_has(typval_T *argvars, typval_T *rettv)
"emacs_tags",
#endif
"eval", /* always present, of course! */
-#ifdef FEAT_EX_EXTRA
- "ex_extra",
-#endif
+ "ex_extra", /* graduated feature */
#ifdef FEAT_SEARCH_EXTRA
"extra_search",
#endif
@@ -13684,16 +13682,12 @@ get_user_input(
if (defstr != NULL)
{
-# ifdef FEAT_EX_EXTRA
int save_ex_normal_busy = ex_normal_busy;
ex_normal_busy = 0;
-# endif
rettv->vval.v_string =
getcmdline_prompt(inputsecret_flag ? NUL : '@', p, echo_attr,
xp_type, xp_arg);
-# ifdef FEAT_EX_EXTRA
ex_normal_busy = save_ex_normal_busy;
-# endif
}
if (inputdialog && rettv->vval.v_string == NULL
&& argvars[1].v_type != VAR_UNKNOWN
diff --git a/src/ex_cmds.c b/src/ex_cmds.c
index 66f1fa6c4..3efdf8bbb 100644
--- a/src/ex_cmds.c
+++ b/src/ex_cmds.c
@@ -18,9 +18,7 @@
# include <float.h>
#endif
-#ifdef FEAT_EX_EXTRA
static int linelen(int *has_tab);
-#endif
static void do_filter(linenr_T line1, linenr_T line2, exarg_T *eap, char_u *cmd, int do_in, int do_out);
#ifdef FEAT_VIMINFO
static char_u *viminfo_filename(char_u *);
@@ -138,7 +136,6 @@ do_ascii(exarg_T *eap UNUSED)
msg(IObuff);
}
-#if defined(FEAT_EX_EXTRA) || defined(PROTO)
/*
* ":left", ":center" and ":right": align text.
*/
@@ -787,7 +784,6 @@ ex_retab(exarg_T *eap)
u_clearline();
}
-#endif
/*
* :move command - move lines line1-line2 to line dest
@@ -6577,7 +6573,6 @@ ex_viusage(exarg_T *eap UNUSED)
do_cmdline_cmd((char_u *)"help normal-index");
}
-#if defined(FEAT_EX_EXTRA) || defined(PROTO)
static void helptags_one(char_u *dir, char_u *ext, char_u *lang, int add_help_tags);
/*
@@ -6962,7 +6957,6 @@ helptags_one(
ga_clear(&ga);
fclose(fd_tags); /* there is no check for an error... */
}
-#endif
#if defined(FEAT_SIGNS) || defined(PROTO)
diff --git a/src/ex_cmds2.c b/src/ex_cmds2.c
index c1adea4c7..2651770a6 100644
--- a/src/ex_cmds2.c
+++ b/src/ex_cmds2.c
@@ -90,9 +90,7 @@ do_debug(char_u *cmd)
tasave_T typeaheadbuf;
int typeahead_saved = FALSE;
int save_ignore_script = 0;
-# ifdef FEAT_EX_EXTRA
int save_ex_normal_busy;
-# endif
int n;
char_u *cmdline = NULL;
char_u *p;
@@ -161,10 +159,8 @@ do_debug(char_u *cmd)
* with the commands being executed. Reset "ex_normal_busy" to avoid
* the side effects of using ":normal". Save the stuff buffer and make
* it empty. Set ignore_script to avoid reading from script input. */
-# ifdef FEAT_EX_EXTRA
save_ex_normal_busy = ex_normal_busy;
ex_normal_busy = 0;
-# endif
if (!debug_greedy)
{
save_typeahead(&typeaheadbuf);
@@ -180,9 +176,7 @@ do_debug(char_u *cmd)
restore_typeahead(&typeaheadbuf);
ignore_script = save_ignore_script;
}
-# ifdef FEAT_EX_EXTRA
ex_normal_busy = save_ex_normal_busy;
-# endif
cmdline_row = msg_row;
msg_starthere();
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index 24df1d17b..028af35c6 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -344,18 +344,8 @@ static void ex_mark(exarg_T *eap);
static char_u *uc_fun_cmd(void);
static char_u *find_ucmd(exarg_T *eap, char_u *p, int *full, expand_T *xp, int *compl);
#endif
-#ifdef FEAT_EX_EXTRA
static void ex_startinsert(exarg_T *eap);
static void ex_stopinsert(exarg_T *eap);
-#else
-# define ex_normal ex_ni
-# define ex_align ex_ni
-# define ex_retab ex_ni
-# define ex_startinsert ex_ni
-# define ex_stopinsert ex_ni
-# define ex_helptags ex_ni
-# define ex_sort ex_ni
-#endif
#ifdef FEAT_FIND_ID
static void ex_checkpath(exarg_T *eap);
static void ex_findpat(exarg_T *eap);
@@ -659,14 +649,12 @@ do_exmode(
MSG(_("Entering Ex mode. Type \"visual\" to go to Normal mode."));
while (exmode_active)
{
-#ifdef FEAT_EX_EXTRA
/* Check for a ":normal" command and no more characters left. */
if (ex_normal_busy > 0 && typebuf.tb_len == 0)
{
exmode_active = FALSE;
break;
}
-#endif
msg_scroll = TRUE;
need_wait_return = FALSE;
ex_pressedreturn = FALSE;
@@ -9860,7 +9848,6 @@ update_topline_cursor(void)
update_curswant();
}
-#if defined(FEAT_EX_EXTRA) || defined(PROTO)
/*
* ":normal[!] {commands}": Execute normal mode commands.
*/
@@ -10062,9 +10049,7 @@ ex_stopinsert(exarg_T *eap UNUSED)
restart_edit = 0;
stop_insert_mode = TRUE;
}
-#endif
-#if defined(FEAT_EX_EXTRA) || defined(FEAT_MENU) || defined(PROTO)
/*
* Execute normal mode command "cmd".
* "remap" can be REMAP_NONE or REMAP_YES.
@@ -10076,10 +10061,7 @@ exec_normal_cmd(char_u *cmd, int remap, int silent)
ins_typebuf(cmd, remap, 0, TRUE, silent);
exec_normal(FALSE);
}
-#endif
-#if defined(FEAT_EX_EXTRA) || defined(FEAT_MENU) || defined(FEAT_EVAL) \
- || defined(PROTO)
/*
* Execute normal_cmd() until there is no typeahead left.
*/
@@ -10097,7 +10079,6 @@ exec_normal(int was_typed)
normal_cmd(&oa, TRUE); /* execute a Normal mode cmd */
}
}
-#endif
#ifdef FEAT_FIND_ID
static void
diff --git a/src/ex_getln.c b/src/ex_getln.c
index 9a49f9f4f..b70755e92 100644
--- a/src/ex_getln.c
+++ b/src/ex_getln.c
@@ -1129,10 +1129,7 @@ getcmdline(
/* In exmode it doesn't make sense to return. Except when
* ":normal" runs out of characters. */
if (exmode_active
-#ifdef FEAT_EX_EXTRA
- && (ex_normal_busy == 0 || typebuf.tb_len > 0)
-#endif
- )
+ && (ex_normal_busy == 0 || typebuf.tb_len > 0))
goto cmdline_not_changed;
gotesc = TRUE; /* will free ccline.cmdbuff after
diff --git a/src/feature.h b/src/feature.h
index f1a3a4a39..ca81d8972 100644
--- a/src/feature.h
+++ b/src/feature.h
@@ -254,13 +254,6 @@
#endif
/*
- * +ex_extra ":retab", ":right", ":left", ":center", ":normal".
- */
-#if defined(FEAT_NORMAL) || defined(FEAT_CHANNEL)
-# define FEAT_EX_EXTRA
-#endif
-
-/*
* +extra_search 'hlsearch' and 'incsearch' options.
*/
#ifdef FEAT_NORMAL
diff --git a/src/getchar.c b/src/getchar.c
index 7a5756b8e..12e250812 100644
--- a/src/getchar.c
+++ b/src/getchar.c
@@ -1356,8 +1356,6 @@ static int old_mouse_row; /* mouse_row related to old_char */
static int old_mouse_col; /* mouse_col related to old_char */
#endif
-#if defined(FEAT_EVAL) || defined(FEAT_EX_EXTRA) || defined(PROTO)
-
/*
* Save all three kinds of typeahead, so that the user must type at a prompt.
*/
@@ -1406,7 +1404,6 @@ restore_typeahead(tasave_T *tp)
set_input_buf(tp->save_inputbuf);
# endif
}
-#endif
/*
* Open a new script file for the ":source!" command.
@@ -1981,11 +1978,7 @@ vgetorpeek(int advance)
* Using ":normal" can also do this, but it saves the typeahead buffer,
* thus it should be OK. But don't get a key from the user then.
*/
- if (vgetc_busy > 0
-#ifdef FEAT_EX_EXTRA
- && ex_normal_busy == 0
-#endif
- )
+ if (vgetc_busy > 0 && ex_normal_busy == 0)
return NUL;
local_State = get_real_state();
@@ -2605,9 +2598,7 @@ vgetorpeek(int advance)
&& typebuf.tb_len == 1
&& typebuf.tb_buf[typebuf.tb_off] == ESC
&& !no_mapping
-#ifdef FEAT_EX_EXTRA
&& ex_normal_busy == 0
-#endif
&& typebuf.tb_maplen == 0
&& (State & INSERT)
&& (p_timeout
@@ -2729,12 +2720,11 @@ vgetorpeek(int advance)
continue;
}
-#ifdef FEAT_EX_EXTRA
if (ex_normal_busy > 0)
{
-# ifdef FEAT_CMDWIN
+#ifdef FEAT_CMDWIN
static int tc = 0;
-# endif
+#endif
/* No typeahead left and inside ":normal". Must return
* something to avoid getting stuck. When an incomplete
@@ -2753,19 +2743,18 @@ vgetorpeek(int advance)
if (p_im && (State & INSERT))
c = Ctrl_L;
else if ((State & CMDLINE)
-# ifdef FEAT_CMDWIN
+#ifdef FEAT_CMDWIN
|| (cmdwin_type > 0 && tc == ESC)
-# endif
+#endif
)
c = Ctrl_C;
else
c = ESC;
-# ifdef FEAT_CMDWIN
+#ifdef FEAT_CMDWIN
tc = c;
-# endif
+#endif
break;
}
-#endif
/*
* get a character: 3. from the user - update display
@@ -4638,18 +4627,14 @@ eval_map_expr(
/* Forbid changing text or using ":normal" to avoid most of the bad side
* effects. Also restore the cursor position. */
++textlock;
-#ifdef FEAT_EX_EXTRA
++ex_normal_lock;
-#endif
set_vim_var_char(c); /* set v:char to the typed character */
save_cursor = curwin->w_cursor;
save_msg_col = msg_col;
save_msg_row = msg_row;
p = eval_to_string(expr, NULL, FALSE);
--textlock;
-#ifdef FEAT_EX_EXTRA
--ex_normal_lock;
-#endif
curwin->w_cursor = save_cursor;
msg_col = save_msg_col;
msg_row = save_msg_row;
diff --git a/src/globals.h b/src/globals.h
index 103aff66d..4c1b41fed 100644
--- a/src/globals.h
+++ b/src/globals.h
@@ -995,10 +995,8 @@ EXTERN typebuf_T typebuf /* typeahead buffer */
= {NULL, NULL, 0, 0, 0, 0, 0, 0, 0}
#endif
;
-#ifdef FEAT_EX_EXTRA
EXTERN int ex_normal_busy INIT(= 0); /* recursiveness of ex_normal() */
EXTERN int ex_normal_lock INIT(= 0); /* forbid use of ex_normal() */
-#endif
#ifdef FEAT_EVAL
EXTERN int ignore_script INIT(= FALSE); /* ignore script input */
#endif
@@ -1573,9 +1571,7 @@ EXTERN char_u e_maxmempat[] INIT(= N_("E363: pattern uses more memory than 'maxm
EXTERN char_u e_emptybuf[] INIT(= N_("E749: empty buffer"));
EXTERN char_u e_nobufnr[] INIT(= N_("E86: Buffer %ld does not exist"));
-#ifdef FEAT_EX_EXTRA
EXTERN char_u e_invalpat[] INIT(= N_("E682: Invalid search pattern or delimiter"));
-#endif
EXTERN char_u e_bufloaded[] INIT(= N_("E139: File is loaded in another buffer"));
#if defined(FEAT_SYN_HL) || \
(defined(FEAT_INS_EXPAND) && defined(FEAT_COMPL_FUNC))
diff --git a/src/normal.c b/src/normal.c
index 2aa068d99..d4b4b70fc 100644
--- a/src/normal.c
+++ b/src/normal.c
@@ -8924,11 +8924,7 @@ nv_esc(cmdarg_T *cap)
/* A CTRL-C is often used at the start of a menu. When 'insertmode' is
* set return to Insert mode afterwards. */
- if (restart_edit == 0 && goto_im()
-#ifdef FEAT_EX_EXTRA
- && ex_normal_busy == 0
-#endif
- )
+ if (restart_edit == 0 && goto_im() && ex_normal_busy == 0)
restart_edit = 'a';
}
diff --git a/src/ui.c b/src/ui.c
index 4309248dc..12aa12cbd 100644
--- a/src/ui.c
+++ b/src/ui.c
@@ -1580,7 +1580,6 @@ vim_used_in_input_buf(void)
}
#endif
-#if defined(FEAT_EVAL) || defined(FEAT_EX_EXTRA) || defined(PROTO)
/*
* Return the current contents of the input buffer and make it empty.
* The returned pointer must be passed to set_input_buf() later.
@@ -1624,7 +1623,6 @@ set_input_buf(char_u *p)
vim_free(gap);
}
}
-#endif
#if defined(FEAT_GUI) \
|| defined(FEAT_MOUSE_GPM) || defined(FEAT_SYSMOUSE) \
@@ -1701,15 +1699,12 @@ push_raw_key(char_u *s, int len)
}
#endif
-#if defined(FEAT_GUI) || defined(FEAT_EVAL) || defined(FEAT_EX_EXTRA) \
- || defined(PROTO)
/* Remove everything from the input buffer. Called when ^C is found */
void
trash_input_buf(void)
{
inbufcount = 0;
}
-#endif
/*
* Read as much data from the input buffer as possible up to maxlen, and store
diff --git a/src/version.c b/src/version.c
index 78fdb7c46..b521511f4 100644
--- a/src/version.c
+++ b/src/version.c
@@ -221,11 +221,7 @@ static char *(features[]) =
#else
"-eval",
#endif
-#ifdef FEAT_EX_EXTRA
"+ex_extra",
-#else
- "-ex_extra",
-#endif
#ifdef FEAT_SEARCH_EXTRA
"+extra_search",
#else
@@ -747,6 +743,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 1222,
+/**/
1221,
/**/
1220,