diff options
author | James McCoy <jamessan@jamessan.com> | 2017-06-06 13:38:23 -0400 |
---|---|---|
committer | James McCoy <jamessan@jamessan.com> | 2017-06-06 21:38:31 -0400 |
commit | bf4de3f6f761bc73801eadffc63a0c18d00c2db7 (patch) | |
tree | 10e22f433544b571b428e0fb5f532bb78e2cb760 /test/functional/eval/msgpack_functions_spec.lua | |
parent | d69286c065a27706b1b8c8992be1bf5238f433a7 (diff) | |
download | rneovim-bf4de3f6f761bc73801eadffc63a0c18d00c2db7.tar.gz rneovim-bf4de3f6f761bc73801eadffc63a0c18d00c2db7.tar.bz2 rneovim-bf4de3f6f761bc73801eadffc63a0c18d00c2db7.zip |
functests/msgpack: Correct representation of literal INT64_MIN
In order to generate INT64_MIN from literal values, it's necessary to
use "-0x7fffffffffffffff - 1". Using "-0x8000000000000000" causes the
value to get clamped to INT64_MAX and then negated.
Diffstat (limited to 'test/functional/eval/msgpack_functions_spec.lua')
-rw-r--r-- | test/functional/eval/msgpack_functions_spec.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/functional/eval/msgpack_functions_spec.lua b/test/functional/eval/msgpack_functions_spec.lua index 8ed01d4996..b241635dfe 100644 --- a/test/functional/eval/msgpack_functions_spec.lua +++ b/test/functional/eval/msgpack_functions_spec.lua @@ -352,7 +352,7 @@ describe('msgpack*() functions', function() eq(1, eval('type(parsed[0]) == type(0) ' .. '|| parsed[0]._TYPE is v:msgpack_types.integer')) if eval('type(parsed[0]) == type(0)') == 1 then - command('call assert_equal(-0x8000000000000000, parsed[0])') + command('call assert_equal(-0x7fffffffffffffff - 1, parsed[0])') eq({}, eval('v:errors')) else eq({_TYPE={}, _VAL={-1, 2, 0, 0}}, eval('parsed[0]')) |