Go to the documentation of this file.
18 #ifndef GEOS_LINEARALGEBRA_INTERFACES_COMMON_HPP_
19 #define GEOS_LINEARALGEBRA_INTERFACES_COMMON_HPP_
26 #define GEOS_LAI_RUNTIME_ASSERT 1
27 #if GEOS_LAI_RUNTIME_ASSERT
33 #define GEOS_LAI_ASSERT( expr ) GEOS_ERROR_IF( !(expr), "" )
40 #define GEOS_LAI_ASSERT_MSG( expr, msg ) GEOS_ERROR_IF( !(expr), msg )
47 #define GEOS_LAI_ASSERT_EQ( lhs, rhs ) GEOS_ERROR_IF_NE( lhs, rhs )
54 #define GEOS_LAI_ASSERT_NE( lhs, rhs ) GEOS_ERROR_IF_EQ( lhs, rhs )
61 #define GEOS_LAI_ASSERT_GT( lhs, rhs ) GEOS_ERROR_IF_GE( rhs, lhs )
68 #define GEOS_LAI_ASSERT_GE( lhs, rhs ) GEOS_ERROR_IF_GT( rhs, lhs )
75 #define GEOS_LAI_ASSERT( expr ) GEOS_ASSERT( expr )
82 #define GEOS_LAI_ASSERT_MSG( expr, msg ) GEOS_ASSERT_MSG( expr, msg )
89 #define GEOS_LAI_ASSERT_EQ( lhs, rhs ) GEOS_ASSERT_EQ( lhs, rhs )
96 #define GEOS_LAI_ASSERT_NE( lhs, rhs ) GEOS_ASSERT_NE( lhs, rhs )
103 #define GEOS_LAI_ASSERT_GT( lhs, rhs ) GEOS_ASSERT_GT( lhs, rhs )
110 #define GEOS_LAI_ASSERT_GE( lhs, rhs ) GEOS_ASSERT_GE( lhs, rhs )
117 #define GEOS_LAI_CHECK_ERROR( call ) \
119 auto const ierr = call; \
120 GEOS_ERROR_IF_NE_MSG( ierr, 0, "Error in call to " << #call ); \
127 #define GEOS_LAI_CHECK_ERROR_NNEG( call ) \
129 auto const ierr = call; \
130 GEOS_ERROR_IF_GT_MSG( 0, ierr, "Error in call to " << #call ); \