#include "Preprocessor.h"
#include "trace.h"
Go to the source code of this file.
◆ _detail_ARMARX_MAKE_ENUM_CONVERTERS
◆ _detail_ARMARX_MAKE_ENUM_CONVERTERS_i
#define _detail_ARMARX_MAKE_ENUM_CONVERTERS_i |
( |
|
r, |
|
|
|
data, |
|
|
|
elem |
|
) |
| |
Value:
Definition at line 31 of file enum.h.
◆ ARMARX_MAKE_ENUM_AND_CONVERTERS
#define ARMARX_MAKE_ENUM_AND_CONVERTERS |
( |
|
name, |
|
|
|
... |
|
) |
| |
Value: enum class name \
{ \
__VA_ARGS__ \
}; \
ARMARX_MAKE_ENUM_CONVERTERS(name, __VA_ARGS__)
Definition at line 62 of file enum.h.
◆ ARMARX_MAKE_ENUM_CONVERTERS
#define ARMARX_MAKE_ENUM_CONVERTERS |
( |
|
type, |
|
|
|
... |
|
) |
| |
Value: static_assert(std::is_enum_v<type>, \
"Parameters to ARMARX_MAKE_ENUM_CONVERTERS must be enum types"); \
{ \
using base = std::underlying_type_t<type>; \
{ \
} \
throw std::invalid_argument{
"Unknown enum value " +
std::to_string(
static_cast<base
>(
v))}; \
} \
inline std::ostream&
operator<<(std::ostream& out, type
v) \
{ \
} \
inline type operator++(type& x) \
{ \
return x = (type)(((int)(x) + 1)); \
} \
inline type operator++(type& x, int) \
{ \
type y = x; \
x = (type)(((int)(x) + 1)); \
return y; \
}
Definition at line 35 of file enum.h.