aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/util/Macros.h
diff options
context:
space:
mode:
authorGravatar Eugene Zhulenev <ezhulenev@google.com>2018-07-18 16:32:55 -0700
committerGravatar Eugene Zhulenev <ezhulenev@google.com>2018-07-18 16:32:55 -0700
commit086ded5c85457f813cddaec03f6a53c561f8652d (patch)
tree2449735ad394b44deb476014763ebbac51269237 /Eigen/src/Core/util/Macros.h
parent79d4129cce4055955e7a340822df31b6f8d25edc (diff)
Disable type traits for GCC < 5.1.0
Diffstat (limited to 'Eigen/src/Core/util/Macros.h')
-rw-r--r--Eigen/src/Core/util/Macros.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/Eigen/src/Core/util/Macros.h b/Eigen/src/Core/util/Macros.h
index adf25ee9b..985406953 100644
--- a/Eigen/src/Core/util/Macros.h
+++ b/Eigen/src/Core/util/Macros.h
@@ -396,7 +396,7 @@
#define EIGEN_HIPCC __HIPCC__
// We need to include hip_runtime.h here because it pulls in
- // ++ hip_common.h which contains the define for __HIP_DEVICE_COMPILE__
+ // ++ hip_common.h which contains the define for __HIP_DEVICE_COMPILE__
// ++ host_defines.h which contains the defines for the __host__ and __device__ macros
#include <hip/hip_runtime.h>
@@ -541,7 +541,9 @@
// Does the compiler support type_traits?
#ifndef EIGEN_HAS_TYPE_TRAITS
-#if EIGEN_MAX_CPP_VER>=11 && (EIGEN_HAS_CXX11 || EIGEN_COMP_MSVC >= 1700)
+#if EIGEN_MAX_CPP_VER>=11 && (EIGEN_HAS_CXX11 || EIGEN_COMP_MSVC >= 1700) \
+ && (!EIGEN_COMP_GNUC || EIGEN_GNUC_AT_LEAST(5, 1))
+ // ^^ Full support of type traits was added only to GCC 5.1.0.
#define EIGEN_HAS_TYPE_TRAITS 1
#define EIGEN_INCLUDE_TYPE_TRAITS
#else