diff --git a/Eigen/src/Core/DenseBase.h b/Eigen/src/Core/DenseBase.h index 3e2bcafd9..e2429be93 100644 --- a/Eigen/src/Core/DenseBase.h +++ b/Eigen/src/Core/DenseBase.h @@ -214,9 +214,7 @@ template class DenseBase */ void resize(int size) { -#ifdef EIGEN_NO_DEBUG - EIGEN_ARG_UNUSED(size); -#endif + EIGEN_ONLY_USED_FOR_DEBUG(size); ei_assert(size == this->size() && "DenseBase::resize() does not actually allow to resize."); } @@ -226,10 +224,8 @@ template class DenseBase */ void resize(int rows, int cols) { -#ifdef EIGEN_NO_DEBUG - EIGEN_ARG_UNUSED(rows); - EIGEN_ARG_UNUSED(cols); -#endif + EIGEN_ONLY_USED_FOR_DEBUG(rows); + EIGEN_ONLY_USED_FOR_DEBUG(cols); ei_assert(rows == this->rows() && cols == this->cols() && "DenseBase::resize() does not actually allow to resize."); } diff --git a/Eigen/src/Core/TriangularMatrix.h b/Eigen/src/Core/TriangularMatrix.h index 632acc2d7..3eb52a5bb 100644 --- a/Eigen/src/Core/TriangularMatrix.h +++ b/Eigen/src/Core/TriangularMatrix.h @@ -89,10 +89,8 @@ template class TriangularBase : public EigenBase void check_coordinates(int row, int col) { -#ifdef EIGEN_NO_DEBUG - EIGEN_ARG_UNUSED(row); - EIGEN_ARG_UNUSED(col); -#endif + EIGEN_ONLY_USED_FOR_DEBUG(row); + EIGEN_ONLY_USED_FOR_DEBUG(col); ei_assert(col>=0 && col=0 && row=row) || (Mode==Lower && col<=row) diff --git a/Eigen/src/Core/util/Macros.h b/Eigen/src/Core/util/Macros.h index 9b277128c..787182444 100644 --- a/Eigen/src/Core/util/Macros.h +++ b/Eigen/src/Core/util/Macros.h @@ -172,8 +172,6 @@ #define EIGEN_UNUSED #endif -#define EIGEN_ARG_UNUSED(x) (void)x; - #if (defined __GNUC__) #define EIGEN_ASM_COMMENT(X) asm("#"X) #else