MADNESS 0.10.1
Classes | Namespaces | Macros
tensorexcept.h File Reference

Declares and implements TensorException. More...

#include <iosfwd>
#include <exception>
#include <madness/tensor/basetensor.h>
Include dependency graph for tensorexcept.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  madness::TensorException
 Tensor is intended to throw only TensorExceptions. More...
 

Namespaces

namespace  madness
 Namespace for all elements and tools of MADNESS.
 

Macros

#define TENSOR_ASSERT(condition, msg, value, t)
 
#define TENSOR_EXCEPTION(msg, value, t)
 
#define TENSOR_EXCEPTION_AT(F, L)   TENSOR_STRINGIZE(F) "(" TENSOR_STRINGIZE(L) ")"
 
#define TENSOR_STRINGIZE(X)   #X
 

Detailed Description

Declares and implements TensorException.

Macro Definition Documentation

◆ TENSOR_ASSERT

#define TENSOR_ASSERT (   condition,
  msg,
  value,
 
)
Value:
do {if (!(condition)) \
throw ::madness::TensorException("TENSOR ASSERTION FAILED: " TENSOR_EXCEPTION_AT( __FILE__, __LINE__ ) ": " msg , \
#condition,value,t,__LINE__,__FUNCTION__,__FILE__); \
} while (0)
#define TENSOR_EXCEPTION_AT(F, L)
Definition tensorexcept.h:124

◆ TENSOR_EXCEPTION

#define TENSOR_EXCEPTION (   msg,
  value,
 
)
Value:
throw ::madness::TensorException("TENSOR EXCEPTION: " TENSOR_EXCEPTION_AT( __FILE__, __LINE__ ) ": " msg , \
0,value,t,__LINE__,__FUNCTION__,__FILE__)

◆ TENSOR_EXCEPTION_AT

#define TENSOR_EXCEPTION_AT (   F,
  L 
)    TENSOR_STRINGIZE(F) "(" TENSOR_STRINGIZE(L) ")"

◆ TENSOR_STRINGIZE

#define TENSOR_STRINGIZE (   X)    #X