assertion.hh File Reference
#include <boost/scope_exit.hpp>
#include <hpp/util/config.hh>
#include <hpp/util/exception.hh>
Include dependency graph for assertion.hh:

Namespaces

 hpp
 

Macros

#define HPP_ENABLE_ASSERTIONS
 
#define HPP_ASSERT(CONDITION)
 Define HPP_ASSERT. More...
 
#define HPP_PRECONDITION(CONDITION)   HPP_ASSERT (CONDITION)
 Define macro for precondition checking. More...
 

Functions

 hpp::HPP_MAKE_EXCEPTION (HPP_UTIL_DLLAPI, AssertionError)
 

Macro Definition Documentation

#define HPP_ASSERT (   CONDITION)
Value:
do { \
bool _x = (CONDITION); \
if (!_x) \
(::hpp::AssertionError, \
#CONDITION " evaluates to false"); \
} while (0)
#define HPP_THROW_EXCEPTION(TYPE, MSG)
Launch a HPP exception (generic macro).
Definition: exception.hh:64

Define HPP_ASSERT.

Throw an ::hpp::AssertionError if macro argument evaluates to false.

#define HPP_ENABLE_ASSERTIONS
#define HPP_PRECONDITION (   CONDITION)    HPP_ASSERT (CONDITION)

Define macro for precondition checking.