diff options
author | ii14 <59243201+ii14@users.noreply.github.com> | 2023-04-07 21:08:16 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-07 21:08:16 +0200 |
commit | 04933b1ea968f958d2541dd65fd33ebb503caac3 (patch) | |
tree | 430e333892c440dccce4d1b4606c83ab36f817c5 /src/nvim/quickfix.c | |
parent | 9408f2dcf7cade2631688300e9b58eed6bc5219a (diff) | |
download | rneovim-04933b1ea968f958d2541dd65fd33ebb503caac3.tar.gz rneovim-04933b1ea968f958d2541dd65fd33ebb503caac3.tar.bz2 rneovim-04933b1ea968f958d2541dd65fd33ebb503caac3.zip |
refactor: remove redundant casts
Diffstat (limited to 'src/nvim/quickfix.c')
-rw-r--r-- | src/nvim/quickfix.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/nvim/quickfix.c b/src/nvim/quickfix.c index 8d9dc4e9c8..e4b624179f 100644 --- a/src/nvim/quickfix.c +++ b/src/nvim/quickfix.c @@ -374,8 +374,8 @@ int qf_init(win_T *wp, const char *restrict efile, char *restrict errorformat, i qi = ll_get_or_alloc_list(wp); } - return qf_init_ext(qi, qi->qf_curlist, (char *)efile, curbuf, NULL, errorformat, - newlist, (linenr_T)0, (linenr_T)0, (char *)qf_title, enc); + return qf_init_ext(qi, qi->qf_curlist, efile, curbuf, NULL, errorformat, + newlist, (linenr_T)0, (linenr_T)0, qf_title, enc); } // Maximum number of bytes allowed per line while reading an errorfile. @@ -3228,7 +3228,7 @@ void qf_list(exarg_T *eap) static void qf_fmt_text(garray_T *gap, const char *restrict text) FUNC_ATTR_NONNULL_ALL { - const char *p = (char *)text; + const char *p = text; while (*p != NUL) { if (*p == '\n') { @@ -4286,11 +4286,11 @@ static char *make_get_fullcmd(const char *makecmd, const char *fname) len += strlen(p_sp) + strlen(fname) + 3; } char *const cmd = xmalloc(len); - snprintf(cmd, len, "%s%s%s", p_shq, (char *)makecmd, p_shq); + snprintf(cmd, len, "%s%s%s", p_shq, makecmd, p_shq); // If 'shellpipe' empty: don't redirect to 'errorfile'. if (*p_sp != NUL) { - append_redir(cmd, len, p_sp, (char *)fname); + append_redir(cmd, len, p_sp, fname); } // Display the fully formed command. Output a newline if there's something @@ -7112,7 +7112,7 @@ static void hgr_search_in_rtp(qf_list_T *qfl, regmatch_T *p_regmatch, const char while (*p != NUL && !got_int) { copy_option_part(&p, NameBuff, MAXPATHL, ","); - hgr_search_files_in_dir(qfl, NameBuff, p_regmatch, (char *)lang); + hgr_search_files_in_dir(qfl, NameBuff, p_regmatch, lang); } } |