aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/util/SymbolicIndex.h
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2017-01-19 20:34:18 +0100
committerGravatar Gael Guennebaud <g.gael@free.fr>2017-01-19 20:34:18 +0100
commit4d302a080c775290acf23935f233cebbe19540f4 (patch)
tree1c2512ce2b8f954e2a193bcba851af3077bba55d /Eigen/src/Core/util/SymbolicIndex.h
parent54f3fbee246744d2cb3aeeb9c52ee32a159b29c5 (diff)
Recover compile-time size from seq(A,B) when A and B are fixed values. (c++11 only)
Diffstat (limited to 'Eigen/src/Core/util/SymbolicIndex.h')
-rw-r--r--Eigen/src/Core/util/SymbolicIndex.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/Eigen/src/Core/util/SymbolicIndex.h b/Eigen/src/Core/util/SymbolicIndex.h
index 5e9465db8..62058760b 100644
--- a/Eigen/src/Core/util/SymbolicIndex.h
+++ b/Eigen/src/Core/util/SymbolicIndex.h
@@ -163,6 +163,13 @@ struct is_symbolic {
enum { value = internal::is_convertible<T,BaseExpr<T> >::value };
};
+// Specialization for functions, because is_convertible fails in this case.
+// Useful in c++98/11 mode when testing is_symbolic<decltype(fix<N>)>
+template<typename T>
+struct is_symbolic<T (*)()> {
+ enum { value = false };
+};
+
/** Represents the actual value of a symbol identified by its tag
*
* It is the return type of SymbolValue::operator=, and most of the time this is only way it is used.