Commit 54999f4e authored by Sergey Vojtovich's avatar Sergey Vojtovich

Use std::isfinite in C++ code

This is addition to parent revision fixing build failures.
parent 031fa6d4
......@@ -2873,7 +2873,7 @@ int Field_decimal::store(double nr)
return 1;
}
if (!isfinite(nr)) // Handle infinity as special case
if (!std::isfinite(nr)) // Handle infinity as special case
{
overflow(nr < 0.0);
return 1;
......
......@@ -237,7 +237,7 @@ class Item_func :public Item_func_or_sum
*/
inline double check_float_overflow(double value)
{
return isfinite(value) ? value : raise_float_overflow();
return std::isfinite(value) ? value : raise_float_overflow();
}
/**
Throw an error if the input BIGINT value represented by the
......
......@@ -2641,7 +2641,7 @@ String *Item_func_format::val_str_ascii(String *str)
return 0; /* purecov: inspected */
nr= my_double_round(nr, (longlong) dec, FALSE, FALSE);
str->set_real(nr, dec, &my_charset_numeric);
if (!isfinite(nr))
if (!std::isfinite(nr))
return str;
str_length=str->length();
}
......
......@@ -355,7 +355,7 @@ mbr_join_square(
/* Check if finite (not infinity or NaN),
so we don't get NaN in calculations */
if (!isfinite(square)) {
if (!std::isfinite(square)) {
return DBL_MAX;
}
......
......@@ -1952,7 +1952,7 @@ rtr_estimate_n_rows_in_range(
mtr.commit();
if (!isfinite(area)) {
if (!std::isfinite(area)) {
return(HA_POS_ERROR);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment