0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

patch 8.2.1532: compiler warning for conversion of size_t to long

Problem:    Compiler warning for conversion of size_t to long.
Solution:   Add type cast.
This commit is contained in:
Bram Moolenaar
2020-08-28 16:38:11 +02:00
parent 7a3330fc57
commit 2566054a7f
2 changed files with 3 additions and 1 deletions

View File

@@ -5392,7 +5392,7 @@ string_slice(char_u *str, varnumber_T first, varnumber_T last)
if (start_byte < 0)
start_byte = 0; // first index very negative: use zero
if (last == -1)
end_byte = slen;
end_byte = (long)slen;
else
{
end_byte = char_idx2byte(str, slen, last);

View File

@@ -754,6 +754,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
1532,
/**/
1531,
/**/