summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-08-21 22:39:35 +0200
committerBram Moolenaar <Bram@vim.org>2016-08-21 22:39:35 +0200
commit9baf297c99cc35adb921bee04369499d76438889 (patch)
tree2950b9566bc892687dd90839d1da41ce5f68a98a
parentde7762a2c1498e2dc43586feb5f982d661799f85 (diff)
patch 7.4.2239v7.4.2239
Problem: Warning for missing declaration of skip_vimgrep_pat(). (John Marriott) Solution: Move it to another file.
-rw-r--r--src/ex_cmds.c54
-rw-r--r--src/proto/ex_cmds.pro1
-rw-r--r--src/proto/quickfix.pro3
-rw-r--r--src/quickfix.c54
-rw-r--r--src/version.c2
5 files changed, 58 insertions, 56 deletions
diff --git a/src/ex_cmds.c b/src/ex_cmds.c
index e727ecc186..5c79e95941 100644
--- a/src/ex_cmds.c
+++ b/src/ex_cmds.c
@@ -8392,6 +8392,60 @@ ex_drop(exarg_T *eap)
}
#endif
+#if defined(FEAT_QUICKFIX) || defined(FEAT_EVAL) || defined(PROTO)
+/*
+ * Skip over the pattern argument of ":vimgrep /pat/[g][j]".
+ * Put the start of the pattern in "*s", unless "s" is NULL.
+ * If "flags" is not NULL put the flags in it: VGR_GLOBAL, VGR_NOJUMP.
+ * If "s" is not NULL terminate the pattern with a NUL.
+ * Return a pointer to the char just past the pattern plus flags.
+ */
+ char_u *
+skip_vimgrep_pat(char_u *p, char_u **s, int *flags)
+{
+ int c;
+
+ if (vim_isIDc(*p))
+ {
+ /* ":vimgrep pattern fname" */
+ if (s != NULL)
+ *s = p;
+ p = skiptowhite(p);
+ if (s != NULL && *p != NUL)
+ *p++ = NUL;
+ }
+ else
+ {
+ /* ":vimgrep /pattern/[g][j] fname" */
+ if (s != NULL)
+ *s = p + 1;
+ c = *p;
+ p = skip_regexp(p + 1, c, TRUE, NULL);
+ if (*p != c)
+ return NULL;
+
+ /* Truncate the pattern. */
+ if (s != NULL)
+ *p = NUL;
+ ++p;
+
+ /* Find the flags */
+ while (*p == 'g' || *p == 'j')
+ {
+ if (flags != NULL)
+ {
+ if (*p == 'g')
+ *flags |= VGR_GLOBAL;
+ else
+ *flags |= VGR_NOJUMP;
+ }
+ ++p;
+ }
+ }
+ return p;
+}
+#endif
+
#if defined(FEAT_EVAL) || defined(PROTO)
/*
* List v:oldfiles in a nice way.
diff --git a/src/proto/ex_cmds.pro b/src/proto/ex_cmds.pro
index 324608f33e..63f25b50f4 100644
--- a/src/proto/ex_cmds.pro
+++ b/src/proto/ex_cmds.pro
@@ -65,5 +65,6 @@ char_u *get_sign_name(expand_T *xp, int idx);
void set_context_in_sign_cmd(expand_T *xp, char_u *arg);
void ex_smile(exarg_T *eap);
void ex_drop(exarg_T *eap);
+char_u *skip_vimgrep_pat(char_u *p, char_u **s, int *flags);
void ex_oldfiles(exarg_T *eap);
/* vim: set ft=c : */
diff --git a/src/proto/quickfix.pro b/src/proto/quickfix.pro
index 99f5edeefd..d48eb25326 100644
--- a/src/proto/quickfix.pro
+++ b/src/proto/quickfix.pro
@@ -26,9 +26,8 @@ void ex_cc(exarg_T *eap);
void ex_cnext(exarg_T *eap);
void ex_cfile(exarg_T *eap);
void ex_vimgrep(exarg_T *eap);
-char_u *skip_vimgrep_pat(char_u *p, char_u **s, int *flags);
-int get_errorlist_properties(win_T *wp, dict_T *what, dict_T *retdict);
int get_errorlist(win_T *wp, int qf_idx, list_T *list);
+int get_errorlist_properties(win_T *wp, dict_T *what, dict_T *retdict);
int set_errorlist(win_T *wp, list_T *list, int action, char_u *title, dict_T *what);
void ex_cbuffer(exarg_T *eap);
void ex_cexpr(exarg_T *eap);
diff --git a/src/quickfix.c b/src/quickfix.c
index 1995c62729..f808da4995 100644
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -5155,57 +5155,3 @@ ex_helpgrep(exarg_T *eap)
}
#endif /* FEAT_QUICKFIX */
-
-#if defined(FEAT_QUICKFIX) || defined(FEAT_EVAL) || defined(PROTO)
-/*
- * Skip over the pattern argument of ":vimgrep /pat/[g][j]".
- * Put the start of the pattern in "*s", unless "s" is NULL.
- * If "flags" is not NULL put the flags in it: VGR_GLOBAL, VGR_NOJUMP.
- * If "s" is not NULL terminate the pattern with a NUL.
- * Return a pointer to the char just past the pattern plus flags.
- */
- char_u *
-skip_vimgrep_pat(char_u *p, char_u **s, int *flags)
-{
- int c;
-
- if (vim_isIDc(*p))
- {
- /* ":vimgrep pattern fname" */
- if (s != NULL)
- *s = p;
- p = skiptowhite(p);
- if (s != NULL && *p != NUL)
- *p++ = NUL;
- }
- else
- {
- /* ":vimgrep /pattern/[g][j] fname" */
- if (s != NULL)
- *s = p + 1;
- c = *p;
- p = skip_regexp(p + 1, c, TRUE, NULL);
- if (*p != c)
- return NULL;
-
- /* Truncate the pattern. */
- if (s != NULL)
- *p = NUL;
- ++p;
-
- /* Find the flags */
- while (*p == 'g' || *p == 'j')
- {
- if (flags != NULL)
- {
- if (*p == 'g')
- *flags |= VGR_GLOBAL;
- else
- *flags |= VGR_NOJUMP;
- }
- ++p;
- }
- }
- return p;
-}
-#endif
diff --git a/src/version.c b/src/version.c
index 0d3d491967..1cd659f861 100644
--- a/src/version.c
+++ b/src/version.c
@@ -764,6 +764,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 2239,
+/**/
2238,
/**/
2237,