GDCM: gdcmLegacyMacro.h File Reference

GDCM 3.0.25

Macros
gdcmLegacyMacro.h File Reference
`#include "gdcmException.h"`
`#include "gdcmTrace.h"`
Include dependency graph for gdcmLegacyMacro.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Macros
#define | GDCM_LEGACY(method)
#define | GDCM_LEGACY_BODY(method, version)
#define | GDCM_LEGACY_REPLACED_BODY(method, version, replace)
#define | GDCM_NOOP_STATEMENT static_assert(true, "")

## Macro Definition Documentation

## ◆ GDCM_LEGACY

#define GDCM_LEGACY | ( |  | method | ) |

Value:
method;

## ◆ GDCM_LEGACY_BODY

#define GDCM_LEGACY_BODY | ( |  | method,
|  |  | version )

Value:
gdcmWarningMacro(#method " was deprecated for " version " and will be removed in a future version.")
gdcmWarningMacro
#define gdcmWarningMacro(msg)
Warning.
Definition gdcmTrace.h:142

## ◆ GDCM_LEGACY_REPLACED_BODY

#define GDCM_LEGACY_REPLACED_BODY | ( |  | method,
|  |  | version,
|  |  | replace )

Value:
gdcmWarningMacro(#method " was deprecated for " version " and will be removed in a future version. Use " #replace " instead.")

## ◆ GDCM_NOOP_STATEMENT

#define GDCM_NOOP_STATEMENT static_assert(true, "")

The `static_assert(true, "")` idiom is commonly employed for C++11 or greater to ensure that it is compile-time only check that can not be part of the binary file. This allows a macro to be used anywhere that a statement is expected, and to enforce consistent use of ; after a macro. The static_assert is a constexpr that can be used in places where raw statements (i.e. 'do{} while(0)') are not allowed (i.e. after class member function definitions).