diff options
author | Gael Guennebaud <g.gael@free.fr> | 2017-01-17 10:30:21 +0100 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2017-01-17 10:30:21 +0100 |
commit | 23bfcfc15ffca75a0a90440c50781d384ce3fe0c (patch) | |
tree | 4a816b7d3e06b241c368aceb1471e8a6427df9b2 /Eigen/src/Core/util/IntegralConstant.h | |
parent | edff32c2c2377ed02ec7af299fccc8ef09070d62 (diff) |
Add missing overload of get_compile_time for c++98/11
Diffstat (limited to 'Eigen/src/Core/util/IntegralConstant.h')
-rw-r--r-- | Eigen/src/Core/util/IntegralConstant.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/Eigen/src/Core/util/IntegralConstant.h b/Eigen/src/Core/util/IntegralConstant.h index 7f99863a1..003856b20 100644 --- a/Eigen/src/Core/util/IntegralConstant.h +++ b/Eigen/src/Core/util/IntegralConstant.h @@ -47,20 +47,24 @@ protected: }; template<typename T, int Default=Dynamic> struct get_compile_time { - enum { value = Default }; + static const int value = Default; }; template<int N,int Default> struct get_compile_time<fix_t<N>,Default> { - enum { value = N }; + static const int value = N; +}; + +template<int N,int Default> struct get_compile_time<fix_t<N> (*)(),Default> { + static const int value = N; }; template<int N,int Default> struct get_compile_time<variable_or_fixed<N>,Default> { - enum { value = N }; + static const int value = N ; }; template<typename T, int N, int Default> struct get_compile_time<variable_if_dynamic<T,N>,Default> { - enum { value = N }; + static const int value = N; }; |