Tomographer  v5.3
Tomographer C++ Framework Documentation
cxxdefs.h File Reference

(v5.3)

Basic definitions, which may have to be defined before any Eigen headers or further utilities are included. More...

#include <cassert>
#include <cstddef>
#include <cstdlib>
#include <boost/predef.h>
+ Include dependency graph for cxxdefs.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define TOMO_STATIC_ASSERT_EXPR(...)   static_assert(__VA_ARGS__, #__VA_ARGS__)
 Tool for static assertions without message. More...
 
#define tomographer_assert(...)   eigen_assert((__VA_ARGS__) && "assert: " #__VA_ARGS__)
 Assertion test macro.
 
#define TOMOGRAPHER_COMPILER_INFO_STR   /* ... */
 Mark a class declaration as deprecated. More...
 

Detailed Description

Basic definitions, which may have to be defined before any Eigen headers or further utilities are included.

Definition in file cxxdefs.h.

Macro Definition Documentation

§ TOMO_STATIC_ASSERT_EXPR

#define TOMO_STATIC_ASSERT_EXPR (   ...)    static_assert(__VA_ARGS__, #__VA_ARGS__)

Tool for static assertions without message.

Simply use as message to C++11's static_assert() a stringified version of the expression itself.

Definition at line 77 of file cxxdefs.h.

§ TOMOGRAPHER_COMPILER_INFO_STR

#define TOMOGRAPHER_COMPILER_INFO_STR   /* ... */

Mark a class declaration as deprecated.

Use for instance as:

// * template<typename CountType>
// * TOMOGRAPHER_DEPRECATED_CLASS(MyObject) : public Base<CountType> { ... }
// *

Mark a class declaration as deprecated

  Use for instance as:
// * template<typename CountType>
// * TOMOGRAPHER_DEPRECATED_STRUCT(MyObject) : public Base<CountType> { ... }
// *

Mark a function declaration as deprecated

  Use as:
// * TOMOGRAPHER_DEPRECATED_FUNC(double f(int x, int y)) {
// * return (double)x / y;
// * }
// *

Mark a "using x = y" declaration as deprecated

  Use as:
// * // using MyAlias = OriginalType
// * TOMOGRAPHER_DEPRECATED_USING(MyAlias, OriginalType);
// *

Expands to a std::string with a brief descritpion of the compiler used (including version)

Definition at line 217 of file cxxdefs.h.