aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/internal/Util.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/internal/Util.h')
-rw-r--r--src/internal/Util.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/internal/Util.h b/src/internal/Util.h
index c7730d6fb..03df6b097 100644
--- a/src/internal/Util.h
+++ b/src/internal/Util.h
@@ -68,6 +68,14 @@ const int EiDynamic = -1;
#define EI_UNUSED(x) (void)x
+#ifdef __GNUC__
+# define EI_ALWAYS_INLINE __attribute__((always_inline))
+# define EI_RESTRICT __restrict__
+#else
+# define EI_ALWAYS_INLINE
+# define EI_RESTRICT
+#endif
+
#define EI_INHERIT_ASSIGNMENT_OPERATOR(Derived, Op) \
template<typename OtherScalar, typename OtherDerived> \
Derived& operator Op(const EiObject<OtherScalar, OtherDerived>& other) \