From 1d8f1faa8176cd2e4f0cd835e4397b7bb23b5d6f Mon Sep 17 00:00:00 2001
From: Gunter Winkler NDEBUG of
cassert is defined. NDEBUG enables
-release mode, which in turn uses expression templates.
BOOST_UBLAS_NDEBUG to disable all
+bounds, structure and similar checks of uBLAS.
Q: I've written some uBLAS tests, which try to incorrectly assign different matrix types or overrun vector and matrix dimensions. Why don't I get a compile time or runtime diff --git a/include/boost/numeric/ublas/detail/config.hpp b/include/boost/numeric/ublas/detail/config.hpp index 9752c708..376bf60e 100644 --- a/include/boost/numeric/ublas/detail/config.hpp +++ b/include/boost/numeric/ublas/detail/config.hpp @@ -177,7 +177,7 @@ namespace std { // Enable performance options in RELEASE mode -#ifdef NDEBUG +#if defined (NDEBUG) || defined (BOOST_UBLAS_NDEBUG) #ifndef BOOST_UBLAS_INLINE #define BOOST_UBLAS_INLINE inline