From 84bb868f07361af7991abd1f0cdb8017af96c0a5 Mon Sep 17 00:00:00 2001 From: Benoit Jacob Date: Fri, 19 Dec 2008 02:59:04 +0000 Subject: * more MSVC warning fixes from Kenneth Riddile * actually GCC 4.3.0 has a bug, "deprecated" placed at the end of a function prototype doesn't have any effect, moving them to the start of the function prototype makes it actually work! * finish porting the cholesky unit-test to the new LLT/LDLT, after the above fix revealed a deprecated warning --- Eigen/src/Core/MatrixBase.h | 7 ++++++- Eigen/src/Core/util/DisableMSVCWarnings.h | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) (limited to 'Eigen/src/Core') diff --git a/Eigen/src/Core/MatrixBase.h b/Eigen/src/Core/MatrixBase.h index bb3cc0532..0c3a04ff4 100644 --- a/Eigen/src/Core/MatrixBase.h +++ b/Eigen/src/Core/MatrixBase.h @@ -495,7 +495,12 @@ template class MatrixBase * Notice that in the case of a plain matrix or vector (not an expression) this function just returns * a const reference, in order to avoid a useless copy. */ - EIGEN_ALWAYS_INLINE const typename ei_eval::type eval() const + #ifdef _MSC_VER + inline // MSVC 2008 can't force-inline this method and emits a warning, so do just 'inline' + #else + EIGEN_ALWAYS_INLINE + #endif + const typename ei_eval::type eval() const { return typename ei_eval::type(derived()); } diff --git a/Eigen/src/Core/util/DisableMSVCWarnings.h b/Eigen/src/Core/util/DisableMSVCWarnings.h index 8152db5ff..e6c653d70 100644 --- a/Eigen/src/Core/util/DisableMSVCWarnings.h +++ b/Eigen/src/Core/util/DisableMSVCWarnings.h @@ -3,7 +3,7 @@ #ifdef _MSC_VER #pragma warning( push ) - #pragma warning( disable : 4181 4244 4127 ) + #pragma warning( disable : 4181 4244 4127 4211 ) #endif #endif // EIGEN_DISABLEMSVCWARNINGS_H \ No newline at end of file -- cgit v1.2.3