aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/ex_cmds.c
diff options
context:
space:
mode:
authorDundar Goc <gocdundar@gmail.com>2022-05-08 14:43:16 +0200
committerDundar Goc <gocdundar@gmail.com>2022-05-11 23:19:57 +0200
commit85aae12a6dea48621ea2d24a946b3e7b86f9014d (patch)
treed9d45a2bdde3b462f58d98b88694bad0183c2b16 /src/nvim/ex_cmds.c
parent5359be78935dc639c481d74f010fe133dd40290c (diff)
downloadrneovim-85aae12a6dea48621ea2d24a946b3e7b86f9014d.tar.gz
rneovim-85aae12a6dea48621ea2d24a946b3e7b86f9014d.tar.bz2
rneovim-85aae12a6dea48621ea2d24a946b3e7b86f9014d.zip
refactor: replace char_u variables and functions with char
Work on https://github.com/neovim/neovim/issues/459
Diffstat (limited to 'src/nvim/ex_cmds.c')
-rw-r--r--src/nvim/ex_cmds.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/nvim/ex_cmds.c b/src/nvim/ex_cmds.c
index b8ca00a9e8..1dbae13354 100644
--- a/src/nvim/ex_cmds.c
+++ b/src/nvim/ex_cmds.c
@@ -1341,7 +1341,7 @@ static void do_filter(linenr_T line1, linenr_T line2, exarg_T *eap, char *cmd, b
* Vi also doesn't do this and the messages are not very informative.
*/
no_wait_return++; // don't call wait_return() while busy
- if (itmp != NULL && buf_write(curbuf, (char_u *)itmp, NULL, line1, line2, eap,
+ if (itmp != NULL && buf_write(curbuf, itmp, NULL, line1, line2, eap,
false, false, false, true) == FAIL) {
msg_putchar('\n'); // Keep message from buf_write().
no_wait_return--;
@@ -1386,7 +1386,7 @@ static void do_filter(linenr_T line1, linenr_T line2, exarg_T *eap, char *cmd, b
if (do_out) {
if (otmp != NULL) {
- if (readfile((char_u *)otmp, NULL, line2, (linenr_T)0, (linenr_T)MAXLNUM, eap,
+ if (readfile(otmp, NULL, line2, (linenr_T)0, (linenr_T)MAXLNUM, eap,
READ_FILTER, false) != OK) {
if (!aborting()) {
msg_putchar('\n');
@@ -1930,7 +1930,7 @@ int do_write(exarg_T *eap)
}
name_was_missing = curbuf->b_ffname == NULL;
- retval = buf_write(curbuf, (char_u *)ffname, (char_u *)fname, eap->line1, eap->line2,
+ retval = buf_write(curbuf, ffname, fname, eap->line1, eap->line2,
eap, eap->append, eap->forceit, true, false);
// After ":saveas fname" reset 'readonly'.
@@ -5360,7 +5360,7 @@ void fix_help_buffer(void)
* In the "help.txt" and "help.abx" file, add the locally added help
* files. This uses the very first line in the help file.
*/
- char *const fname = (char *)path_tail(curbuf->b_fname);
+ char *const fname = path_tail((char *)curbuf->b_fname);
if (FNAMECMP(fname, "help.txt") == 0
|| (FNAMENCMP(fname, "help.", 5) == 0
&& ASCII_ISALPHA(fname[5])
@@ -5413,8 +5413,8 @@ void fix_help_buffer(void)
}
const char *const f1 = fnames[i1];
const char *const f2 = fnames[i2];
- const char *const t1 = (char *)path_tail((char_u *)f1);
- const char *const t2 = (char *)path_tail((char_u *)f2);
+ const char *const t1 = path_tail(f1);
+ const char *const t2 = path_tail(f2);
const char *const e1 = (char *)STRRCHR(t1, '.');
const char *const e2 = (char *)STRRCHR(t2, '.');
if (e1 == NULL || e2 == NULL) {