diff options
author | dundargoc <33953936+dundargoc@users.noreply.github.com> | 2023-02-11 10:25:24 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-11 10:25:24 +0100 |
commit | 7224c889e0d5d70b99ae377036baa6377c33a568 (patch) | |
tree | dcd43af5075b12db1aae2e1a087bf88599b387ff /src/nvim/diff.c | |
parent | c8c930ea785aa393ebc819139913a9e05f0ccd45 (diff) | |
download | rneovim-7224c889e0d5d70b99ae377036baa6377c33a568.tar.gz rneovim-7224c889e0d5d70b99ae377036baa6377c33a568.tar.bz2 rneovim-7224c889e0d5d70b99ae377036baa6377c33a568.zip |
build: enable MSVC level 3 warnings (#21934)
MSVC has 4 different warning levels: 1 (severe), 2 (significant), 3
(production quality) and 4 (informational). Enabling level 3 warnings
mostly revealed conversion problems, similar to GCC/clang -Wconversion
flag.
Diffstat (limited to 'src/nvim/diff.c')
-rw-r--r-- | src/nvim/diff.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/nvim/diff.c b/src/nvim/diff.c index 032de561b3..3bdc965146 100644 --- a/src/nvim/diff.c +++ b/src/nvim/diff.c @@ -3409,7 +3409,7 @@ static int parse_diff_ed(char *line, diffhunk_T *hunk) linenr_T f1 = getdigits_int32(&p, true, 0); if (*p == ',') { p++; - l1 = getdigits(&p, true, 0); + l1 = getdigits_long(&p, true, 0); } else { l1 = f1; } @@ -3417,10 +3417,10 @@ static int parse_diff_ed(char *line, diffhunk_T *hunk) return FAIL; // invalid diff format } int difftype = (uint8_t)(*p++); - long f2 = getdigits(&p, true, 0); + long f2 = getdigits_long(&p, true, 0); if (*p == ',') { p++; - l2 = getdigits(&p, true, 0); + l2 = getdigits_long(&p, true, 0); } else { l2 = f2; } @@ -3458,18 +3458,18 @@ static int parse_diff_unified(char *line, diffhunk_T *hunk) long oldcount; long newline; long newcount; - long oldline = getdigits(&p, true, 0); + long oldline = getdigits_long(&p, true, 0); if (*p == ',') { p++; - oldcount = getdigits(&p, true, 0); + oldcount = getdigits_long(&p, true, 0); } else { oldcount = 1; } if (*p++ == ' ' && *p++ == '+') { - newline = getdigits(&p, true, 0); + newline = getdigits_long(&p, true, 0); if (*p == ',') { p++; - newcount = getdigits(&p, true, 0); + newcount = getdigits_long(&p, true, 0); } else { newcount = 1; } |