mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
Change array_size result from enum to constexpr.
This commit is contained in:
committed by
Rasmus Munk Larsen
parent
8a73c6490f
commit
feaafda30a
@@ -204,19 +204,19 @@ EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const T& array_get(const array<T, N>& a) {
|
||||
|
||||
template <class T, std::size_t N>
|
||||
struct array_size<array<T, N> > {
|
||||
enum { value = N };
|
||||
static constexpr Index value = N;
|
||||
};
|
||||
template <class T, std::size_t N>
|
||||
struct array_size<array<T, N>&> {
|
||||
enum { value = N };
|
||||
static constexpr Index value = N;
|
||||
};
|
||||
template <class T, std::size_t N>
|
||||
struct array_size<const array<T, N> > {
|
||||
enum { value = N };
|
||||
static constexpr Index value = N;
|
||||
};
|
||||
template <class T, std::size_t N>
|
||||
struct array_size<const array<T, N>&> {
|
||||
enum { value = N };
|
||||
static constexpr Index value = N;
|
||||
};
|
||||
|
||||
} // end namespace internal
|
||||
|
||||
Reference in New Issue
Block a user