aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/eval/userfunc.c
diff options
context:
space:
mode:
authordundargoc <gocdundar@gmail.com>2023-09-29 14:58:48 +0200
committerdundargoc <33953936+dundargoc@users.noreply.github.com>2023-10-03 22:02:55 +0200
commite72b546354cd90bf0cd8ee6dd045538d713009ad (patch)
tree680a28f2e9ca4ab5a3221afbffff4d64cfdef842 /src/nvim/eval/userfunc.c
parent70ec8d60e0dc71c5ca06fdd83698c82b16ea474f (diff)
downloadrneovim-e72b546354cd90bf0cd8ee6dd045538d713009ad.tar.gz
rneovim-e72b546354cd90bf0cd8ee6dd045538d713009ad.tar.bz2
rneovim-e72b546354cd90bf0cd8ee6dd045538d713009ad.zip
refactor: the long goodbye
long is 32 bits on windows, while it is 64 bits on other architectures. This makes the type suboptimal for a codebase meant to be cross-platform. Replace it with more appropriate integer types.
Diffstat (limited to 'src/nvim/eval/userfunc.c')
-rw-r--r--src/nvim/eval/userfunc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/eval/userfunc.c b/src/nvim/eval/userfunc.c
index 6b9801b805..e4adf9f340 100644
--- a/src/nvim/eval/userfunc.c
+++ b/src/nvim/eval/userfunc.c
@@ -1126,7 +1126,7 @@ void call_user_func(ufunc_T *fp, int argcount, typval_T *argvars, typval_T *rett
msg_puts(", ");
}
if (argvars[i].v_type == VAR_NUMBER) {
- msg_outnum((long)argvars[i].vval.v_number);
+ msg_outnum((int)argvars[i].vval.v_number);
} else {
// Do not want errors such as E724 here.
emsg_off++;
@@ -2263,7 +2263,7 @@ void ex_function(exarg_T *eap)
}
msg_putchar('\n');
if (!eap->forceit) {
- msg_outnum((long)j + 1);
+ msg_outnum(j + 1);
if (j < 9) {
msg_putchar(' ');
}