#11648 closed Bugs (fixed)
div infinite loop
Reported by: | Owned by: | John Maddock | |
---|---|---|---|
Milestone: | Boost 1.61.0 | Component: | multiprecision |
Version: | Boost 1.59.0 | Severity: | Problem |
Keywords: | Cc: |
Description
Dividing two values of fixed 256-bit unchecked unsigned integer type can never finish.
Type:
using u256 = boost::multiprecision::number<boost::multiprecision::cpp_int_backend<256, 256, boost::multiprecision::unsigned_magnitude, boost::multiprecision::unchecked, void>>;
Values:
u256 a{"0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFBA"}; u256 b{"0x1DAE6076B981DAE6076B981DAE6076B981DAE6076B981DAE6076B981DAE6077"};
Full test: https://gist.github.com/chfast/9136896f1ee1d214b7a6
Attachments (1)
Change History (5)
by , 7 years ago
Attachment: | boost-div.cpp added |
---|
comment:1 by , 7 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Thanks for the test case. Now fixed in https://github.com/boostorg/multiprecision/commit/a1eafc4228d90dca05f180cd5db183c58c90721a.
comment:4 by , 6 years ago
Milestone: | To Be Determined → Boost 1.61.0 |
---|
Note:
See TracTickets
for help on using tickets.
test case