diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-11-18 15:24:39 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-18 15:24:39 +0800 |
commit | f70963f8380723ada33cdb78289cf16f15c7be83 (patch) | |
tree | 6c16bcbdf3e091056656287c3f7a5f7e4398e83b /src/nvim/quickfix.c | |
parent | 282cbc2350986c3fc1edb507c4facc8d8fe8cd97 (diff) | |
parent | 41c85ac2ef71be6ec1d62fdb7b6d6b1a30ab24ee (diff) | |
download | rneovim-f70963f8380723ada33cdb78289cf16f15c7be83.tar.gz rneovim-f70963f8380723ada33cdb78289cf16f15c7be83.tar.bz2 rneovim-f70963f8380723ada33cdb78289cf16f15c7be83.zip |
Merge pull request #21101 from zeertzjq/vim-8.2.4494
vim-patch:8.2.{4494,4496}: find_tags() function is too long
Diffstat (limited to 'src/nvim/quickfix.c')
-rw-r--r-- | src/nvim/quickfix.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/nvim/quickfix.c b/src/nvim/quickfix.c index d7590f6f57..27a0842016 100644 --- a/src/nvim/quickfix.c +++ b/src/nvim/quickfix.c @@ -4308,10 +4308,17 @@ void ex_make(exarg_T *eap) incr_quickfix_busy(); - int res = qf_init(wp, fname, (eap->cmdidx != CMD_make - && eap->cmdidx != CMD_lmake) ? p_gefm : p_efm, - (eap->cmdidx != CMD_grepadd && eap->cmdidx != CMD_lgrepadd), - qf_cmdtitle(*eap->cmdlinep), enc); + char *errorformat = p_efm; + bool newlist = true; + + if (eap->cmdidx != CMD_make && eap->cmdidx != CMD_lmake) { + errorformat = p_gefm; + } + if (eap->cmdidx == CMD_grepadd || eap->cmdidx == CMD_lgrepadd) { + newlist = false; + } + + int res = qf_init(wp, fname, errorformat, newlist, qf_cmdtitle(*eap->cmdlinep), enc); qf_info_T *qi = &ql_info; if (wp != NULL) { |