[Bugzilla] [Bug 15506] New: uint64() is puzzled over [uint64(%inf)/2 uint64(%inf)]
bugzilla.admin at scilab.org
bugzilla.admin at scilab.org
Sun Mar 25 20:41:44 CEST 2018
http://bugzilla.scilab.org/show_bug.cgi?id=15506
--------- Bug Summary -----------
uint64() is puzzled over [uint64(%inf)/2 uint64(%inf)]
---------- Changed by ------------
sgougeon at free.fr
---------- What changed ----------
bug_id, short_desc, product, version, rep_platform, op_sys, bug_status, bug_severity, priority, component, assigned_to, reporter
Bug ID: 15506
Summary: uint64() is puzzled over [uint64(%inf)/2
uint64(%inf)]
Product: Scilab software
Version: 6.0.1
Hardware: (not used)
OS: All OS
Status: NEW
Severity: Medium
Priority: (field not used)
Component: Numerical Math
Assignee: bugzilla.admin at scilab.org
Reporter: sgougeon at free.fr
BUG DESCRIPTION:
----------------
--> imax = uint64(%inf)
imax =
18446744073709551615 // OK
--> x=2^64-1
x =
1.845D+19 // OK
--> x<=imax
ans =
T /// OK
--> uint64(x)
ans =
9223372036854775808 // BUG
--> uint64(x)==imax/2
ans =
T // !
ERROR LOG:
----------
none. Wrong behavior
HOW TO REPRODUCE THE BUG:
-------------------------
imax = uint64(%inf)
x = 2^64-1
x <= imax
uint64(x)
uint64(x)==imax/2
OTHER INFORMATION:
------------------
This bug has complicated a lot the design of the unit tests
test_run compatibility_functions mtlb_int_uint
--
You are receiving this mail because:
You are watching all bug changes.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/bugzilla/attachments/20180325/32a65595/attachment.htm>
More information about the Bugzilla
mailing list