# HG changeset patch # User Bram Moolenaar # Date 1603735204 -3600 # Node ID 8968ed4ba4bac57940aa4d7c2476da0838789127 # Parent 3a50936283297842b54e16c5dacb05fa08030ae1 patch 8.2.1906: warning for signed/unsigned Commit: https://github.com/vim/vim/commit/a360dbe3b63bdca93bbf8cc431578a446e8ce14c Author: Bram Moolenaar Date: Mon Oct 26 18:46:53 2020 +0100 patch 8.2.1906: warning for signed/unsigned Problem: Warning for signed/unsigned. Solution: Use size_t instead of int. (Mike Williams) diff --git a/src/proto/usercmd.pro b/src/proto/usercmd.pro --- a/src/proto/usercmd.pro +++ b/src/proto/usercmd.pro @@ -15,6 +15,6 @@ void ex_comclear(exarg_T *eap); void uc_clear(garray_T *gap); void ex_delcommand(exarg_T *eap); size_t add_win_cmd_modifers(char_u *buf, cmdmod_T *cmod, int *multi_mods); -int produce_cmdmods(char_u *buf, cmdmod_T *cmod, int quote); +size_t produce_cmdmods(char_u *buf, cmdmod_T *cmod, int quote); void do_ucmd(exarg_T *eap); /* vim: set ft=c : */ diff --git a/src/usercmd.c b/src/usercmd.c --- a/src/usercmd.c +++ b/src/usercmd.c @@ -1269,10 +1269,10 @@ add_win_cmd_modifers(char_u *buf, cmdmod * Generate text for the "cmod" command modifiers. * If "buf" is NULL just return the length. */ - int + size_t produce_cmdmods(char_u *buf, cmdmod_T *cmod, int quote) { - int result = 0; + size_t result = 0; int multi_mods = 0; int i; typedef struct { diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -751,6 +751,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 1906, +/**/ 1905, /**/ 1904, diff --git a/src/vim9execute.c b/src/vim9execute.c --- a/src/vim9execute.c +++ b/src/vim9execute.c @@ -3530,7 +3530,7 @@ ex_disassemble(exarg_T *eap) case ISN_CMDMOD: { char_u *buf; - int len = produce_cmdmods( + size_t len = produce_cmdmods( NULL, iptr->isn_arg.cmdmod.cf_cmdmod, FALSE); buf = alloc(len + 1);