[Issue 24083] New: Int128.opCmp's behavior with negative numbers is inconsistent with Int128.opEquals
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Fri Aug 11 22:21:58 UTC 2023
https://issues.dlang.org/show_bug.cgi?id=24083
Issue ID: 24083
Summary: Int128.opCmp's behavior with negative numbers is
inconsistent with Int128.opEquals
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P1
Component: phobos
Assignee: nobody at puremagic.com
Reporter: n8sh.secondary at hotmail.com
---
void main()
{
import std.stdio;
import std.int128;
writeln(Int128(-1L) == -1L); // writes true
writeln(Int128(-1L) < -1L); // also writes true !!!
}
---
--
More information about the Digitalmars-d-bugs
mailing list