My Project
errormacro.hh File Reference
#include <iostream>
#include <sstream>
#include <cassert>
#include <stdexcept>
#include <mia/core/defines.hh>
Include dependency graph for errormacro.hh:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define DEBUG_ASSERT_RELEASE_THROW(cond, msg...)
 

Functions

void __append_message (std::ostream &os)
 
template<typename V >
void __append_message (std::ostream &os, const V &v)
 
template<typename V , typename... T>
void __append_message (std::ostream &os, const V &v, T ...t)
 
template<typename... T>
const std::string __create_message (T ...t)
 
template<typename E , typename... T>
create_exception (T ...t)
 helper template to create exceptions with complex messages
 

Macro Definition Documentation

◆ DEBUG_ASSERT_RELEASE_THROW

#define DEBUG_ASSERT_RELEASE_THROW (   cond,
  msg... 
)
Value:
if (!(cond)) { \
std::cerr << "Assertion failed: \'" #cond << "\' " << \
__FILE__ << ":" << __LINE__ << " " \
<< ::mia::__create_message(msg) << "\n"; \
abort(); \
}

Definition at line 99 of file errormacro.hh.

Function Documentation

◆ __append_message() [1/3]

void __append_message ( std::ostream &  os)
inline

Definition at line 44 of file errormacro.hh.

◆ __append_message() [2/3]

template<typename V >
void __append_message ( std::ostream &  os,
const V &  v 
)

Definition at line 39 of file errormacro.hh.

◆ __append_message() [3/3]

template<typename V , typename... T>
void __append_message ( std::ostream &  os,
const V &  v,
T ...  t 
)

Definition at line 49 of file errormacro.hh.

◆ __create_message()

template<typename... T>
const std::string __create_message ( T ...  t)

Definition at line 56 of file errormacro.hh.