0
0
mirror of https://github.com/vim/vim.git synced 2025-10-03 05:14:07 -04:00

patch 8.2.0271: the "num64" feature is available everywhere

Problem:    The "num64" feature is available everywhere and building without
            it causes problems.
Solution:   Graduage the "num64" feature. (James McCoy, closes #5650)
This commit is contained in:
Bram Moolenaar
2020-02-17 22:12:50 +01:00
parent bc2b71d44a
commit 82f654e092
9 changed files with 53 additions and 119 deletions

View File

@@ -1416,10 +1416,6 @@ endfunc
"-------------------------------------------------------------------------------
func Test_num64()
if !has('num64')
return
endif
call assert_notequal( 4294967296, 0)
call assert_notequal(-4294967296, 0)
call assert_equal( 4294967296, 0xFFFFffff + 1)
@@ -1692,27 +1688,15 @@ func Test_compound_assignment_operators()
" Test special cases: division or modulus with 0.
let x = 1
let x /= 0
if has('num64')
call assert_equal(0x7FFFFFFFFFFFFFFF, x)
else
call assert_equal(0x7fffffff, x)
endif
call assert_equal(0x7FFFFFFFFFFFFFFF, x)
let x = -1
let x /= 0
if has('num64')
call assert_equal(-0x7FFFFFFFFFFFFFFF, x)
else
call assert_equal(-0x7fffffff, x)
endif
call assert_equal(-0x7FFFFFFFFFFFFFFF, x)
let x = 0
let x /= 0
if has('num64')
call assert_equal(-0x7FFFFFFFFFFFFFFF - 1, x)
else
call assert_equal(-0x7FFFFFFF - 1, x)
endif
call assert_equal(-0x7FFFFFFFFFFFFFFF - 1, x)
let x = 1
let x %= 0