- Move to_interval(long long) from Interval_arithmetic.h to long_long.h.

This commit is contained in:
Sylvain Pion 2002-08-13 19:42:50 +00:00
parent fa3d26a66f
commit 76f25c3953
4 changed files with 18 additions and 13 deletions

View File

@ -1,3 +1,6 @@
Version 4.143 on 13 August 2002
- Move to_interval(long long) from Interval_arithmetic.h to long_long.h.
Version 4.142 on 12 August 2002
- Fix long long support.

View File

@ -147,18 +147,6 @@ struct Interval_nt : public Interval_base
typedef Interval_nt<false> Interval_nt_advanced; // for back-compatibility
#ifdef CGAL_USE_LONG_LONG
inline
Interval_base
to_interval (const long long & z)
{
Protect_FPU_rounding<true> P(CGAL_FE_TONEAREST);
Interval_nt_advanced approx ((double) z);
FPU_set_cw(CGAL_FE_UPWARD);
return approx + Interval_nt_advanced(Interval_base::Smallest);
}
#endif
template <bool Protected>
#ifndef CGAL_IA_NO_INLINE
inline

View File

@ -1,3 +1,6 @@
4.64 (13 August 02)
- Move to_interval(long long) from Interval_arithmetic.h to long_long.h.
4.63 (12 August 02)
- Shut up a valgrind warning in MP_Float.C.
@ -18,7 +21,7 @@
- Removed _test_sign.C.
4.58 (2 July 02)
- New square(MP_Float) specialization.
- New square(MP_Float) overloading.
----------------------------- CGAL 2.4 -----------------------------

View File

@ -28,6 +28,7 @@
#define CGAL_LONG_LONG_H
#include <CGAL/basic.h>
#include <CGAL/Interval_arithmetic.h>
CGAL_BEGIN_NAMESPACE
@ -96,6 +97,16 @@ inline unsigned long long is_positive(unsigned long long i)
inline unsigned long long abs(unsigned long long i) { return i; }
} // namespace NTS
inline
Interval_base
to_interval (const long long & z)
{
Protect_FPU_rounding<true> P(CGAL_FE_TONEAREST);
Interval_nt_advanced approx ((double) z);
FPU_set_cw(CGAL_FE_UPWARD);
return approx + Interval_nt_advanced(Interval_base::Smallest);
}
#if (defined(__sparc__) || defined(__sparc) || defined(sparc)) || \
(defined(__sgi__) || defined(__sgi) || defined(sgi)) || \