We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4a15a81 commit 04e6ff1Copy full SHA for 04e6ff1
source/templates/FloatingPoint.h
@@ -71,11 +71,11 @@ namespace vx::floating_point {
71
auto factor = static_cast<T>( 1 );
72
if ( _equal == Equal::Relative ) {
73
74
- factor = std::max( std::abs( _left ), std::abs( _right ) );
+ factor = std::max<T>( std::abs( _left ), std::abs( _right ) );
75
}
76
else if ( _equal == Equal::Combined ) {
77
78
- factor = std::max( { factor, std::abs( _left ), std::abs( _right ) } );
+ factor = std::max<T>( factor, std::max<T>( std::abs( _left ), std::abs( _right ) ) );
79
80
return std::abs( _left - _right ) <= std::numeric_limits<T>::epsilon() * factor;
81
0 commit comments