diff options
author | zeertzjq <zeertzjq@outlook.com> | 2023-03-05 09:18:42 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-05 09:18:42 +0800 |
commit | 419819b6245e120aba8897e3ddea711b2cd0246c (patch) | |
tree | 6a86105155ec9abc9553d3ed69a30321f4be9a01 /src/nvim/viml/parser/expressions.c | |
parent | b44b8e7687ece66f4c535182071223d78ca54ad0 (diff) | |
download | rneovim-419819b6245e120aba8897e3ddea711b2cd0246c.tar.gz rneovim-419819b6245e120aba8897e3ddea711b2cd0246c.tar.bz2 rneovim-419819b6245e120aba8897e3ddea711b2cd0246c.zip |
vim-patch:9.0.1380: CTRL-X on 2**64 subtracts two (#22530)
Problem: CTRL-X on 2**64 subtracts two. (James McCoy)
Solution: Correct computation for large number. (closes vim/vim#12103)
https://github.com/vim/vim/commit/5fb78c3fa5c996c08a65431d698bd2c251eef5c7
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'src/nvim/viml/parser/expressions.c')
-rw-r--r-- | src/nvim/viml/parser/expressions.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/viml/parser/expressions.c b/src/nvim/viml/parser/expressions.c index 53224f2ee9..35d9de069b 100644 --- a/src/nvim/viml/parser/expressions.c +++ b/src/nvim/viml/parser/expressions.c @@ -376,7 +376,7 @@ LexExprToken viml_pexpr_next_token(ParserState *const pstate, const int flags) } if (exp_start) { vim_str2nr(pline.data + exp_start, NULL, NULL, 0, NULL, &exp_part, - (int)(ret.len - exp_start), false); + (int)(ret.len - exp_start), false, NULL); } if (exp_negative) { exp_part += frac_size; @@ -394,7 +394,7 @@ LexExprToken viml_pexpr_next_token(ParserState *const pstate, const int flags) int len; int prep; vim_str2nr(pline.data, &prep, &len, STR2NR_ALL, NULL, - &ret.data.num.val.integer, (int)pline.size, false); + &ret.data.num.val.integer, (int)pline.size, false, NULL); ret.len = (size_t)len; const uint8_t bases[] = { [0] = 10, |