mirror of https://github.com/CGAL/cgal
Replace isinf with !is_finite.
This commit is contained in:
parent
e09d25c15d
commit
ea2d486b81
|
|
@ -91,7 +91,7 @@ template <> class Real_embeddable_traits< Gmpq >
|
|||
MPFR_DECL_INIT (y, 53); /* Assume IEEE-754 */
|
||||
int r = mpfr_set_q (y, x.mpq(), MPFR_RNDA);
|
||||
double i = mpfr_get_d (y, MPFR_RNDA); /* EXACT but can overflow */
|
||||
if (r == 0 && !isinf (i))
|
||||
if (r == 0 && is_finite (i))
|
||||
return std::pair<double, double>(i, i);
|
||||
else
|
||||
{
|
||||
|
|
|
|||
|
|
@ -133,7 +133,7 @@ public:
|
|||
MPFR_DECL_INIT (y, 53); /* Assume IEEE-754 */
|
||||
int r = mpfr_set_z (y, x.mpz(), MPFR_RNDA);
|
||||
double i = mpfr_get_d (y, MPFR_RNDA); /* EXACT but can overflow */
|
||||
if (r == 0 && !isinf (i))
|
||||
if (r == 0 && is_finite (i))
|
||||
return std::pair<double, double>(i, i);
|
||||
else
|
||||
{
|
||||
|
|
|
|||
|
|
@ -210,7 +210,7 @@ class Real_embeddable_traits< mpq_class >
|
|||
MPFR_DECL_INIT (y, 53); /* Assume IEEE-754 */
|
||||
int r = mpfr_set_q (y, x.get_mpq_t(), MPFR_RNDA);
|
||||
double i = mpfr_get_d (y, MPFR_RNDA); /* EXACT but can overflow */
|
||||
if (r == 0 && !isinf (i))
|
||||
if (r == 0 && is_finite (i))
|
||||
return std::pair<double, double>(i, i);
|
||||
else
|
||||
{
|
||||
|
|
|
|||
|
|
@ -274,7 +274,7 @@ public:
|
|||
MPFR_DECL_INIT (y, 53); /* Assume IEEE-754 */
|
||||
int r = mpfr_set_z (y, x.get_mpz_t(), MPFR_RNDA);
|
||||
double i = mpfr_get_d (y, MPFR_RNDA); /* EXACT but can overflow */
|
||||
if (r == 0 && !isinf (i))
|
||||
if (r == 0 && is_finite (i))
|
||||
return std::pair<double, double>(i, i);
|
||||
else
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue