Opened 7 years ago

#12069 new Bugs

hexfloat not respected for float128

Reported by: Ruslan <b7.10110111@…> Owned by: John Maddock
Milestone: To Be Determined Component: multiprecision
Version: Boost 1.60.0 Severity: Problem
Keywords: Cc:

Description

Here's an example program:

#include <boost/multiprecision/float128.hpp>
#include <boost/version.hpp>
#include <iostream>
#include <iomanip>

template<typename Float>
void test()
{
    std::cout << std::hexfloat << Float(1.3516809557473623e+236Q) << "\n";
}

int main()
{
    std::cout << "boost " BOOST_LIB_VERSION << "\n";
    test<double>();
    test<boost::multiprecision::float128>();
}

Its output is

boost 1_60
0x1.5417c8p+784
1.351681e+236

while in both cases hexadecimal format was requested. Here second and third lines should be identical.

Change History (0)

Note: See TracTickets for help on using tickets.