summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2005-09-20 23:22:24 +0000
committerBram Moolenaar <Bram@vim.org>2005-09-20 23:22:24 +0000
commitbfd8fc0529f46612f7b3efca6c7b3305e70ac374 (patch)
treef6b8a9bdb8bf573cea7862b3ab5ad41dfb5d1b46 /src
parent60a795aad6ade281146a5343b416f21825af5364 (diff)
downloadvim-git-bfd8fc0529f46612f7b3efca6c7b3305e70ac374.tar.gz
updated for version 7.0149v7.0149
Diffstat (limited to 'src')
-rw-r--r--src/diff.c8
-rw-r--r--src/eval.c50
-rw-r--r--src/ex_cmds.c6
-rw-r--r--src/ex_cmds2.c6
-rw-r--r--src/ex_docmd.c137
-rw-r--r--src/ex_getln.c63
-rw-r--r--src/fileio.c9
-rw-r--r--src/if_cscope.c2
-rw-r--r--src/main.c2
-rw-r--r--src/mbyte.c2
-rw-r--r--src/message.c2
-rw-r--r--src/misc2.c3
-rw-r--r--src/proto/ex_docmd.pro1
-rw-r--r--src/proto/ex_getln.pro3
-rw-r--r--src/quickfix.c2
-rw-r--r--src/version.h4
16 files changed, 213 insertions, 87 deletions
diff --git a/src/diff.c b/src/diff.c
index f2af8e274..b6f936e8f 100644
--- a/src/diff.c
+++ b/src/diff.c
@@ -668,18 +668,18 @@ ex_diffupdate(eap)
for (;;)
{
ok = FALSE;
- fd = fopen((char *)tmp_orig, "w");
+ fd = mch_fopen((char *)tmp_orig, "w");
if (fd != NULL)
{
fwrite("line1\n", (size_t)6, (size_t)1, fd);
fclose(fd);
- fd = fopen((char *)tmp_new, "w");
+ fd = mch_fopen((char *)tmp_new, "w");
if (fd != NULL)
{
fwrite("line2\n", (size_t)6, (size_t)1, fd);
fclose(fd);
diff_file(tmp_orig, tmp_new, tmp_diff);
- fd = fopen((char *)tmp_diff, "r");
+ fd = mch_fopen((char *)tmp_diff, "r");
if (fd != NULL)
{
char_u linebuf[LBUFLEN];
@@ -1144,7 +1144,7 @@ diff_read(idx_orig, idx_new, fname)
long count_orig, count_new;
int notset = TRUE; /* block "*dp" not set yet */
- fd = fopen((char *)fname, "r");
+ fd = mch_fopen((char *)fname, "r");
if (fd == NULL)
{
EMSG(_("E98: Cannot read diff output"));
diff --git a/src/eval.c b/src/eval.c
index e087b7aab..2365b3fed 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -504,6 +504,7 @@ static void f_getchar __ARGS((typval_T *argvars, typval_T *rettv));
static void f_getcharmod __ARGS((typval_T *argvars, typval_T *rettv));
static void f_getcmdline __ARGS((typval_T *argvars, typval_T *rettv));
static void f_getcmdpos __ARGS((typval_T *argvars, typval_T *rettv));
+static void f_getcmdtype __ARGS((typval_T *argvars, typval_T *rettv));
static void f_getcwd __ARGS((typval_T *argvars, typval_T *rettv));
static void f_getfontname __ARGS((typval_T *argvars, typval_T *rettv));
static void f_getfperm __ARGS((typval_T *argvars, typval_T *rettv));
@@ -6769,6 +6770,7 @@ static struct fst
{"getcharmod", 0, 0, f_getcharmod},
{"getcmdline", 0, 0, f_getcmdline},
{"getcmdpos", 0, 0, f_getcmdpos},
+ {"getcmdtype", 0, 0, f_getcmdtype},
{"getcwd", 0, 0, f_getcwd},
{"getfontname", 0, 1, f_getfontname},
{"getfperm", 1, 1, f_getfperm},
@@ -6799,7 +6801,7 @@ static struct fst
{"iconv", 3, 3, f_iconv},
{"indent", 1, 1, f_indent},
{"index", 2, 4, f_index},
- {"input", 1, 2, f_input},
+ {"input", 1, 3, f_input},
{"inputdialog", 1, 3, f_inputdialog},
{"inputlist", 1, 1, f_inputlist},
{"inputrestore", 0, 0, f_inputrestore},
@@ -9438,6 +9440,24 @@ f_getcmdpos(argvars, rettv)
}
/*
+ * "getcmdtype()" function
+ */
+/*ARGSUSED*/
+ static void
+f_getcmdtype(argvars, rettv)
+ typval_T *argvars;
+ typval_T *rettv;
+{
+ rettv->v_type = VAR_STRING;
+ rettv->vval.v_string = alloc(2);
+ if (rettv->vval.v_string != NULL)
+ {
+ rettv->vval.v_string[0] = get_cmdline_type();
+ rettv->vval.v_string[1] = NUL;
+ }
+}
+
+/*
* "getcwd()" function
*/
/*ARGSUSED*/
@@ -10794,6 +10814,8 @@ f_input(argvars, rettv)
char_u buf[NUMBUFLEN];
int cmd_silent_save = cmd_silent;
char_u *defstr = (char_u *)"";
+ int xp_type = EXPAND_NOTHING;
+ char_u *xp_arg = NULL;
rettv->v_type = VAR_STRING;
@@ -10835,9 +10857,31 @@ f_input(argvars, rettv)
stuffReadbuffSpec(defstr);
}
+ if (argvars[2].v_type != VAR_UNKNOWN)
+ {
+ char_u *xp_name;
+ int xp_namelen;
+ long argt;
+
+ rettv->vval.v_string = NULL;
+
+ xp_name = get_tv_string_buf_chk(&argvars[2], buf);
+ if (xp_name == NULL)
+ return;
+
+ xp_namelen = STRLEN(xp_name);
+
+ if (parse_compl_arg(xp_name, xp_namelen, &xp_type, &argt, &xp_arg)
+ == FAIL)
+ return;
+ }
+
if (defstr != NULL)
rettv->vval.v_string =
- getcmdline_prompt(inputsecret_flag ? NUL : '@', p, echo_attr);
+ getcmdline_prompt(inputsecret_flag ? NUL : '@', p, echo_attr,
+ xp_type, xp_arg);
+
+ vim_free(xp_arg);
/* since the user typed this, no need to wait for return */
need_wait_return = FALSE;
@@ -17680,10 +17724,8 @@ list_func_head(fp, indent)
}
msg_putchar(')');
msg_clr_eos();
-#ifdef FEAT_EVAL
if (p_verbose > 0)
last_set_msg(fp->uf_script_ID);
-#endif
}
/*
diff --git a/src/ex_cmds.c b/src/ex_cmds.c
index 529baf7b3..c35ad3862 100644
--- a/src/ex_cmds.c
+++ b/src/ex_cmds.c
@@ -5688,7 +5688,7 @@ fix_help_buffer()
{
for (fi = 0; fi < fcount; ++fi)
{
- fd = fopen((char *)fnames[fi], "r");
+ fd = mch_fopen((char *)fnames[fi], "r");
if (fd != NULL)
{
vim_fgets(IObuff, IOSIZE, fd);
@@ -5953,7 +5953,7 @@ helptags_one(dir, ext, tagfname)
STRCPY(NameBuff, dir);
add_pathsep(NameBuff);
STRCAT(NameBuff, tagfname);
- fd_tags = fopen((char *)NameBuff, "w");
+ fd_tags = mch_fopen((char *)NameBuff, "w");
if (fd_tags == NULL)
{
EMSG2(_("E152: Cannot open %s for writing"), NameBuff);
@@ -5988,7 +5988,7 @@ helptags_one(dir, ext, tagfname)
*/
for (fi = 0; fi < filecount && !got_int; ++fi)
{
- fd = fopen((char *)files[fi], "r");
+ fd = mch_fopen((char *)files[fi], "r");
if (fd == NULL)
{
EMSG2(_("E153: Unable to open %s for reading"), files[fi]);
diff --git a/src/ex_cmds2.c b/src/ex_cmds2.c
index bd8d748e8..c635bfc4c 100644
--- a/src/ex_cmds2.c
+++ b/src/ex_cmds2.c
@@ -167,7 +167,7 @@ do_debug(cmd)
if (!debug_greedy)
save_typeahead(&typeaheadbuf);
- cmdline = getcmdline_prompt('>', NULL, 0);
+ cmdline = getcmdline_prompt('>', NULL, 0, EXPAND_NOTHING, NULL);
if (!debug_greedy)
restore_typeahead(&typeaheadbuf);
@@ -1031,7 +1031,7 @@ profile_dump()
if (profile_fname != NULL)
{
- fd = fopen((char *)profile_fname, "w");
+ fd = mch_fopen((char *)profile_fname, "w");
if (fd == NULL)
EMSG2(_(e_notopen), profile_fname);
else
@@ -1149,7 +1149,7 @@ script_dump_profile(fd)
fprintf(fd, "\n");
fprintf(fd, "count total (s) self (s)\n");
- sfd = fopen((char *)si->sn_name, "r");
+ sfd = mch_fopen((char *)si->sn_name, "r");
if (sfd == NULL)
fprintf(fd, "Cannot open file!\n");
else
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index 6e6e2971f..72ffc18c4 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -5267,66 +5267,15 @@ invalid_count:
}
else if (STRNICMP(attr, "complete", attrlen) == 0)
{
- char_u *arg = NULL;
- size_t arglen = 0;
-
if (val == NULL)
{
- EMSG(_("E179: argument required for complete"));
+ EMSG(_("E179: argument required for -complete"));
return FAIL;
}
- /* Look for any argument part - which is the part after any ',' */
- for (i = 0; i < (int)vallen; ++i)
- {
- if (val[i] == ',')
- {
- arg = &val[i + 1];
- arglen = vallen - i - 1;
- vallen = i;
- break;
- }
- }
-
- for (i = 0; command_complete[i].expand != 0; ++i)
- {
- if (STRLEN(command_complete[i].name) == vallen
- && STRNCMP(val, command_complete[i].name, vallen) == 0)
- {
- *compl = command_complete[i].expand;
- if (command_complete[i].expand == EXPAND_BUFFERS)
- *argt |= BUFNAME;
- else if (command_complete[i].expand == EXPAND_DIRECTORIES
- || command_complete[i].expand == EXPAND_FILES)
- *argt |= XFILE;
- break;
- }
- }
- if (command_complete[i].expand == 0)
- {
- EMSG2(_("E180: Invalid complete value: %s"), val);
- return FAIL;
- }
-#if defined(FEAT_EVAL) && defined(FEAT_CMDL_COMPL)
- if (*compl != EXPAND_USER_DEFINED && *compl != EXPAND_USER_LIST &&
- arg != NULL)
-#else
- if (arg != NULL)
-#endif
- {
- EMSG(_("E468: Completion argument only allowed for custom completion"));
- return FAIL;
- }
-#if defined(FEAT_EVAL) && defined(FEAT_CMDL_COMPL)
- if ((*compl == EXPAND_USER_DEFINED || *compl == EXPAND_USER_LIST) &&
- arg == NULL)
- {
- EMSG(_("E467: Custom completion requires a function argument"));
+ if (parse_compl_arg(val, (int)vallen, compl, argt, compl_arg)
+ == FAIL)
return FAIL;
- }
- if (arg != NULL)
- *compl_arg = vim_strnsave(arg, (int)arglen);
-#endif
}
else
{
@@ -5914,6 +5863,86 @@ get_user_cmd_complete(xp, idx)
#endif /* FEAT_USR_CMDS */
+#if defined(FEAT_USR_CMDS) || defined(FEAT_EVAL) || defined(PROTO)
+/*
+ * Parse a completion argument "value[vallen]".
+ * The detected completion goes in "*complp", argument type in "*argt".
+ * When there is an argument, for function and user defined completion, it's
+ * copied to allocated memory and stored in "*compl_arg".
+ * Returns FAIL if something is wrong.
+ */
+ int
+parse_compl_arg(value, vallen, complp, argt, compl_arg)
+ char_u *value;
+ int vallen;
+ int *complp;
+ long *argt;
+ char_u **compl_arg;
+{
+ char_u *arg = NULL;
+ size_t arglen = 0;
+ int i;
+ int valend = vallen;
+
+ /* Look for any argument part - which is the part after any ',' */
+ for (i = 0; i < vallen; ++i)
+ {
+ if (value[i] == ',')
+ {
+ arg = &value[i + 1];
+ arglen = vallen - i - 1;
+ valend = i;
+ break;
+ }
+ }
+
+ for (i = 0; command_complete[i].expand != 0; ++i)
+ {
+ if (STRLEN(command_complete[i].name) == valend
+ && STRNCMP(value, command_complete[i].name, valend) == 0)
+ {
+ *complp = command_complete[i].expand;
+ if (command_complete[i].expand == EXPAND_BUFFERS)
+ *argt |= BUFNAME;
+ else if (command_complete[i].expand == EXPAND_DIRECTORIES
+ || command_complete[i].expand == EXPAND_FILES)
+ *argt |= XFILE;
+ break;
+ }
+ }
+
+ if (command_complete[i].expand == 0)
+ {
+ EMSG2(_("E180: Invalid complete value: %s"), value);
+ return FAIL;
+ }
+
+# if defined(FEAT_EVAL) && defined(FEAT_CMDL_COMPL)
+ if (*complp != EXPAND_USER_DEFINED && *complp != EXPAND_USER_LIST
+ && arg != NULL)
+# else
+ if (arg != NULL)
+# endif
+ {
+ EMSG(_("E468: Completion argument only allowed for custom completion"));
+ return FAIL;
+ }
+
+# if defined(FEAT_EVAL) && defined(FEAT_CMDL_COMPL)
+ if ((*complp == EXPAND_USER_DEFINED || *complp == EXPAND_USER_LIST)
+ && arg == NULL)
+ {
+ EMSG(_("E467: Custom completion requires a function argument"));
+ return FAIL;
+ }
+
+ if (arg != NULL)
+ *compl_arg = vim_strnsave(arg, (int)arglen);
+# endif
+ return OK;
+}
+#endif
+
static void
ex_colorscheme(eap)
exarg_T *eap;
diff --git a/src/ex_getln.c b/src/ex_getln.c
index 6f6550b79..b69076fcc 100644
--- a/src/ex_getln.c
+++ b/src/ex_getln.c
@@ -31,6 +31,11 @@ struct cmdline_info
int cmdattr; /* attributes for prompt */
int overstrike; /* Typing mode on the command line. Shared by
getcmdline() and put_on_cmdline(). */
+ int xp_context; /* type of expansion */
+# ifdef FEAT_EVAL
+ char_u *xp_arg; /* user-defined expansion arg */
+ int input_fn; /* Invoked for input() function */
+# endif
};
static struct cmdline_info ccline; /* current cmdline_info */
@@ -254,6 +259,15 @@ getcmdline(firstc, count, indent)
xpc.xp_context = EXPAND_NOTHING;
xpc.xp_backslash = XP_BS_NONE;
+#if defined(FEAT_EVAL)
+ if (ccline.input_fn)
+ {
+ xpc.xp_context = ccline.xp_context;
+ xpc.xp_pattern = ccline.cmdbuff;
+ xpc.xp_arg = ccline.xp_arg;
+ }
+#endif
+
/*
* Avoid scrolling when called by a recursive do_cmdline(), e.g. when
* doing ":@0" when register 0 doesn't contain a CR.
@@ -414,6 +428,13 @@ getcmdline(firstc, count, indent)
if (p_wmnu && wild_menu_showing != 0)
{
int skt = KeyTyped;
+ int old_RedrawingDisabled;
+
+ if (ccline.input_fn)
+ {
+ old_RedrawingDisabled = RedrawingDisabled;
+ RedrawingDisabled = 0;
+ }
if (wild_menu_showing == WM_SCROLLED)
{
@@ -442,6 +463,8 @@ getcmdline(firstc, count, indent)
# endif
redraw_statuslines();
}
+ if (ccline.input_fn)
+ RedrawingDisabled = old_RedrawingDisabled;
KeyTyped = skt;
wild_menu_showing = 0;
}
@@ -1791,10 +1814,12 @@ returncmd:
* Returns the command line in allocated memory, or NULL.
*/
char_u *
-getcmdline_prompt(firstc, prompt, attr)
+getcmdline_prompt(firstc, prompt, attr, xp_context, xp_arg)
int firstc;
char_u *prompt; /* command line prompt */
int attr; /* attributes for prompt */
+ int xp_context; /* type of expansion */
+ char_u *xp_arg; /* user-defined expansion argument */
{
char_u *s;
struct cmdline_info save_ccline;
@@ -1803,6 +1828,11 @@ getcmdline_prompt(firstc, prompt, attr)
save_cmdline(&save_ccline);
ccline.cmdprompt = prompt;
ccline.cmdattr = attr;
+# ifdef FEAT_EVAL
+ ccline.xp_context = xp_context;
+ ccline.xp_arg = xp_arg;
+ ccline.input_fn = (firstc == '@');
+# endif
s = getcmdline(firstc, 1L, 0);
restore_cmdline(&save_ccline);
/* Restore msg_col, the prompt from input() may have changed it. */
@@ -1830,7 +1860,7 @@ cmdline_charsize(idx)
static void
set_cmdspos()
{
- if (ccline.cmdfirstc)
+ if (ccline.cmdfirstc != NUL)
ccline.cmdspos = 1 + ccline.cmdindent;
else
ccline.cmdspos = 0 + ccline.cmdindent;
@@ -2222,7 +2252,7 @@ redrawcmd_preedit()
old_row = msg_row;
old_col = msg_col;
- cmdspos = ((ccline.cmdfirstc) ? 1 : 0) + ccline.cmdindent;
+ cmdspos = ((ccline.cmdfirstc != NUL) ? 1 : 0) + ccline.cmdindent;
# ifdef FEAT_MBYTE
if (has_mbyte)
@@ -2813,14 +2843,14 @@ redrawcmdprompt()
if (cmd_silent)
return;
- if (ccline.cmdfirstc)
+ if (ccline.cmdfirstc != NUL)
msg_putchar(ccline.cmdfirstc);
if (ccline.cmdprompt != NULL)
{
msg_puts_attr(ccline.cmdprompt, ccline.cmdattr);
ccline.cmdindent = msg_col + (msg_row - cmdline_row) * Columns;
/* do the reverse of set_cmdspos() */
- if (ccline.cmdfirstc)
+ if (ccline.cmdfirstc != NUL)
--ccline.cmdindent;
}
else
@@ -3843,6 +3873,7 @@ set_expand_context(xp)
if (ccline.cmdfirstc != ':'
#ifdef FEAT_EVAL
&& ccline.cmdfirstc != '>' && ccline.cmdfirstc != '='
+ && !ccline.input_fn
#endif
)
{
@@ -3875,6 +3906,12 @@ set_cmd_context(xp, str, len, col)
if (ccline.cmdfirstc == '=')
/* pass CMD_SIZE because there is no real command */
set_context_for_expression(xp, str, CMD_SIZE);
+ else if (ccline.input_fn)
+ {
+ xp->xp_context = ccline.xp_context;
+ xp->xp_pattern = ccline.cmdbuff;
+ xp->xp_arg = ccline.xp_arg;
+ }
else
#endif
while (nextcomm != NULL)
@@ -4838,6 +4875,22 @@ set_cmdline_pos(pos)
}
/*
+ * Get the current command-line type.
+ * Returns ':' or '/' or '?' or '@' or '>'
+ * Only works when the command line is being edited.
+ * Returns NUL when something is wrong.
+ */
+ int
+get_cmdline_type()
+{
+ struct cmdline_info *p = get_ccline_ptr();
+
+ if (p == NULL)
+ return NUL;
+ return p->cmdfirstc;
+}
+
+/*
* Calculate history index from a number:
* num > 0: seen as identifying number of a history entry
* num < 0: relative position in history wrt newest entry
diff --git a/src/fileio.c b/src/fileio.c
index d49d87b69..916fdcb5d 100644
--- a/src/fileio.c
+++ b/src/fileio.c
@@ -3483,12 +3483,11 @@ buf_write(buf, fname, sfname, start, end, eap, append, forceit,
}
if (backup != NULL)
{
-
/*
- * Delete any existing backup and move the current version to
- * the backup. For safety, we don't remove the backup until
- * the write has finished successfully. And if the 'backup'
- * option is set, leave it around.
+ * Delete any existing backup and move the current version
+ * to the backup. For safety, we don't remove the backup
+ * until the write has finished successfully. And if the
+ * 'backup' option is set, leave it around.
*/
/*
* If the renaming of the original file to the backup file
diff --git a/src/if_cscope.c b/src/if_cscope.c
index 7653308f1..24d7d0659 100644
--- a/src/if_cscope.c
+++ b/src/if_cscope.c
@@ -1098,7 +1098,7 @@ cs_find_common(opt, pat, forceit, verbose)
FILE *f;
char_u *tmp = vim_tempname('c');
- f = fopen((char *)tmp, "w");
+ f = mch_fopen((char *)tmp, "w");
cs_file_results(f, nummatches);
fclose(f);
/* '-' starts a new error list */
diff --git a/src/main.c b/src/main.c
index 0067b1c2f..898205e28 100644
--- a/src/main.c
+++ b/src/main.c
@@ -201,7 +201,7 @@ main
#endif
#ifdef STARTUPTIME
- time_fd = fopen(STARTUPTIME, "a");
+ time_fd = mch_fopen(STARTUPTIME, "a");
TIME_MSG("--- VIM STARTING ---");
#endif
diff --git a/src/mbyte.c b/src/mbyte.c
index abdb9e8b3..d057266bf 100644
--- a/src/mbyte.c
+++ b/src/mbyte.c
@@ -161,7 +161,7 @@ xim_log(char *s, ...)
return;
if (fd == NULL)
{
- fd = fopen("xim.log", "w");
+ fd = mch_fopen("xim.log", "w");
if (fd == NULL)
{
EMSG("Cannot open xim.log");
diff --git a/src/message.c b/src/message.c
index b5329bc9c..6daa36550 100644
--- a/src/message.c
+++ b/src/message.c
@@ -3034,7 +3034,7 @@ verbose_open()
/* Only give the error message once. */
verbose_did_open = TRUE;
- verbose_fd = fopen((char *)p_vfile, "a");
+ verbose_fd = mch_fopen((char *)p_vfile, "a");
if (verbose_fd == NULL)
{
EMSG2(_(e_notopen), p_vfile);
diff --git a/src/misc2.c b/src/misc2.c
index 305741554..e691aa96b 100644
--- a/src/misc2.c
+++ b/src/misc2.c
@@ -3512,7 +3512,8 @@ get_crypt_key(store, twice)
cmdline_row = msg_row;
p1 = getcmdline_prompt(NUL, round == 0
? (char_u *)_("Enter encryption key: ")
- : (char_u *)_("Enter same key again: "), 0);
+ : (char_u *)_("Enter same key again: "), 0, EXPAND_NOTHING,
+ NULL);
cmdline_star = FALSE;
if (p1 == NULL)
diff --git a/src/proto/ex_docmd.pro b/src/proto/ex_docmd.pro
index f4df30d76..25601e171 100644
--- a/src/proto/ex_docmd.pro
+++ b/src/proto/ex_docmd.pro
@@ -21,6 +21,7 @@ char_u *get_user_commands __ARGS((expand_T *xp, int idx));
char_u *get_user_cmd_flags __ARGS((expand_T *xp, int idx));
char_u *get_user_cmd_nargs __ARGS((expand_T *xp, int idx));
char_u *get_user_cmd_complete __ARGS((expand_T *xp, int idx));
+int parse_compl_arg __ARGS((char_u *value, int vallen, int *complp, long *argt, char_u **compl_arg));
void not_exiting __ARGS((void));
void handle_drop __ARGS((int filec, char_u **filev, int split));
void alist_clear __ARGS((alist_T *al));
diff --git a/src/proto/ex_getln.pro b/src/proto/ex_getln.pro
index f0d45a31f..fe2752b8d 100644
--- a/src/proto/ex_getln.pro
+++ b/src/proto/ex_getln.pro
@@ -1,6 +1,6 @@
/* ex_getln.c */
char_u *getcmdline __ARGS((int firstc, long count, int indent));
-char_u *getcmdline_prompt __ARGS((int firstc, char_u *prompt, int attr));
+char_u *getcmdline_prompt __ARGS((int firstc, char_u *prompt, int attr, int xp_context, char_u *xp_arg));
char_u *getexline __ARGS((int c, void *dummy, int indent));
char_u *getexmodeline __ARGS((int promptc, void *dummy, int indent));
int cmdline_overstrike __ARGS((void));
@@ -33,6 +33,7 @@ int get_history_idx __ARGS((int histype));
char_u *get_cmdline_str __ARGS((void));
int get_cmdline_pos __ARGS((void));
int set_cmdline_pos __ARGS((int pos));
+int get_cmdline_type __ARGS((void));
char_u *get_history_entry __ARGS((int histype, int idx));
int clr_history __ARGS((int histype));
int del_history_entry __ARGS((int histype, char_u *str));
diff --git a/src/quickfix.c b/src/quickfix.c
index 56f1671ae..113318782 100644
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -3056,7 +3056,7 @@ ex_helpgrep(eap)
+ STRLEN(fnames[fi]) - 3, 3) == 0))
continue;
#endif
- fd = fopen((char *)fnames[fi], "r");
+ fd = mch_fopen((char *)fnames[fi], "r");
if (fd != NULL)
{
lnum = 1;
diff --git a/src/version.h b/src/version.h
index f4c9e7132..0cb24adae 100644
--- a/src/version.h
+++ b/src/version.h
@@ -36,5 +36,5 @@
#define VIM_VERSION_NODOT "vim70aa"
#define VIM_VERSION_SHORT "7.0aa"
#define VIM_VERSION_MEDIUM "7.0aa ALPHA"
-#define VIM_VERSION_LONG "VIM - Vi IMproved 7.0aa ALPHA (2005 Sep 16)"
-#define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.0aa ALPHA (2005 Sep 16, compiled "
+#define VIM_VERSION_LONG "VIM - Vi IMproved 7.0aa ALPHA (2005 Sep 20)"
+#define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.0aa ALPHA (2005 Sep 20, compiled "