Chemical Data Processing Library C++ API - Version 1.2.0
Macros
Check.hpp File Reference

Definition of various preprocessor macros for error checking. More...

#include <algorithm>

Go to the source code of this file.

Macros

#define CDPL_MATH_CHECK(expr, msg, e)
 
#define CDPL_MATH_CHECK_SIZE_EQUALITY(size1, size2, e)   checkSizeEquality<e>(size1, size2)
 
#define CDPL_MATH_CHECK_MAX_SIZE(size, max_size, e)   checkMaxSize<e>(size, max_size)
 

Detailed Description

Definition of various preprocessor macros for error checking.

Macro Definition Documentation

◆ CDPL_MATH_CHECK

#define CDPL_MATH_CHECK (   expr,
  msg,
 
)
Value:
if (!(expr)) { \
throw e(msg); \
}

◆ CDPL_MATH_CHECK_SIZE_EQUALITY

#define CDPL_MATH_CHECK_SIZE_EQUALITY (   size1,
  size2,
 
)    checkSizeEquality<e>(size1, size2)

◆ CDPL_MATH_CHECK_MAX_SIZE

#define CDPL_MATH_CHECK_MAX_SIZE (   size,
  max_size,
 
)    checkMaxSize<e>(size, max_size)