mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
Correct pnegate for floating-point zero.
(cherry picked from commit 8588d8c74b)
This commit is contained in:
committed by
Antonio Sanchez
parent
771e91860b
commit
5547205092
@@ -189,21 +189,9 @@ template<> struct make_unsigned<signed int> { typedef unsigned int type; }
|
||||
template<> struct make_unsigned<unsigned int> { typedef unsigned int type; };
|
||||
template<> struct make_unsigned<signed long> { typedef unsigned long type; };
|
||||
template<> struct make_unsigned<unsigned long> { typedef unsigned long type; };
|
||||
#if EIGEN_COMP_MSVC
|
||||
template<> struct make_unsigned<signed __int64> { typedef unsigned __int64 type; };
|
||||
template<> struct make_unsigned<unsigned __int64> { typedef unsigned __int64 type; };
|
||||
#endif
|
||||
|
||||
// Some platforms define int64_t as `long long` even for C++03, where
|
||||
// `long long` is not guaranteed by the standard. In this case we are missing
|
||||
// the definition for make_unsigned. If we just define it, we run into issues
|
||||
// where `long long` doesn't exist in some compilers for C++03. We therefore add
|
||||
// the specialization for these platforms only.
|
||||
#if EIGEN_OS_MAC || EIGEN_COMP_MINGW
|
||||
template<> struct make_unsigned<unsigned long long> { typedef unsigned long long type; };
|
||||
template<> struct make_unsigned<long long> { typedef unsigned long long type; };
|
||||
#endif
|
||||
#endif
|
||||
|
||||
template <typename T> struct add_const { typedef const T type; };
|
||||
template <typename T> struct add_const<T&> { typedef T& type; };
|
||||
|
||||
Reference in New Issue
Block a user