Fix creation of initial value for computing the max (Fixes PR #805).
Bård spotet a bug after PR #805 was merged. Indead returning -numeric_limits<type>::min() does not make sense for integral values. This commit resorts to returning numeric_limits<type>::min(). Kudos to Bård for his attention.
This commit is contained in:
parent
91fcd61d55
commit
bc0e842ac8
@ -481,7 +481,7 @@ private:
|
||||
// for integral types.
|
||||
if( std::is_integral<Result>::value )
|
||||
{
|
||||
return -std::numeric_limits<Result>::min();
|
||||
return std::numeric_limits<Result>::min();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user