Opened 11 years ago

Closed 11 years ago

#5676 closed Bugs (fixed)

more accurate tests for float types in lexical_cast

Reported by: Antony Polukhin Owned by: Antony Polukhin
Milestone: To Be Determined Component: lexical_cast
Version: Boost 1.46.1 Severity: Problem
Keywords: Cc:

Description

Use BOOST_CHECK_CLOSE_FRACTION(a, b, std::numeric_limits<T>::epsilon() ) instead of BOOST_CHECK_CLOSE(a, b, std::numeric_limits<T>::epsilon()*100 )

std::numeric_limits<T>::epsilon()*100/100 not always equal to std::numeric_limits<T>::epsilon() http://www.parashift.com/c++-faq-lite/newbie.html#faq-29.17

Change History (1)

comment:1 by Antony Polukhin, 11 years ago

Resolution: fixed
Status: newclosed

(In [72955]) Fixes #5676. Tests for float types are now more accurate

Note: See TracTickets for help on using tickets.