diff --git a/Eigen/src/Core/util/EmulateArray.h b/Eigen/src/Core/util/EmulateArray.h index 2b1155245..4bfbbbab0 100644 --- a/Eigen/src/Core/util/EmulateArray.h +++ b/Eigen/src/Core/util/EmulateArray.h @@ -204,19 +204,19 @@ EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const T& array_get(const array& a) { template struct array_size > { - enum { value = N }; + static constexpr Index value = N; }; template struct array_size&> { - enum { value = N }; + static constexpr Index value = N; }; template struct array_size > { - enum { value = N }; + static constexpr Index value = N; }; template struct array_size&> { - enum { value = N }; + static constexpr Index value = N; }; } // end namespace internal diff --git a/Eigen/src/Core/util/Meta.h b/Eigen/src/Core/util/Meta.h index 859d2f18d..d2336ce5d 100644 --- a/Eigen/src/Core/util/Meta.h +++ b/Eigen/src/Core/util/Meta.h @@ -303,30 +303,30 @@ class noncopyable { */ template struct array_size { - enum { value = Dynamic }; + static constexpr Index value = Dynamic; }; template struct array_size> { - enum { value = T::SizeAtCompileTime }; + static constexpr Index value = T::SizeAtCompileTime; }; template struct array_size { - enum { value = N }; + static constexpr Index value = N; }; template struct array_size { - enum { value = N }; + static constexpr Index value = N; }; template struct array_size> { - enum { value = N }; + static constexpr Index value = N; }; template struct array_size> { - enum { value = N }; + static constexpr Index value = N; }; /** \internal