vrpn 07.35
Virtual Reality Peripheral Network
|
Header for assert macros. More...
#include <assert.h>
Go to the source code of this file.
Macros | |
#define | VRPN_CURRENT_FUNCTION "(unknown)" |
Expands to the special preprocessor macro providing a useful description of the current function, where available. | |
#define | VRPN_ASSERT(expr) assert(expr) |
Asserts the truth of expr according to the configuration of vrpn_Assert.h at the time of inclusion. | |
#define | VRPN_ASSERT_MSG(expr, msg) assert((expr) && (msg)) |
Like VRPN_ASSERT(expr) but allows specification of a message to be included in the case of a failed assertion. | |
#define | VRPN_VERIFY(expr) VRPN_ASSERT(expr) |
Typically forwards to VRPN_ASSERT, but in cases where VRPN_ASSERT would expand to nothing (not evaluating the expression), VRPN_VERIFY evaluates the expression but discards the result. | |
#define | VRPN_VERIFY_MSG(expr, msg) VRPN_ASSERT_MSG(expr,msg) |
Like VRPN_VERIFY(expr) but allows specification of a message to be included in the case of a failed assertion. | |
Header for assert macros.
Include guards intentionally omitted, to allow re-inclusion with different options.
Assertions can either do nothing, call an assert handler on failure that prints details to stderr, or call your compiler system's assert.
VRPN_DISABLE_ASSERTS
before including this file to forcibly disable all asserts.VRPN_ENABLE_ASSERT_HANDLER
VRPN_ENABLE_ASSERT_DEBUG_HANDLER
Definition in file vrpn_Assert.h.
#define VRPN_ASSERT | ( | expr | ) | assert(expr) |
Asserts the truth of expr
according to the configuration of vrpn_Assert.h at the time of inclusion.
If not asserting, does not evaluate expression.
Definition at line 152 of file vrpn_Assert.h.
#define VRPN_ASSERT_MSG | ( | expr, | |
msg ) assert((expr) && (msg)) |
Like VRPN_ASSERT(expr) but allows specification of a message to be included in the case of a failed assertion.
Definition at line 153 of file vrpn_Assert.h.
Referenced by vrpn::EndpointIterator::EndpointIterator(), vrpn::OwningPtr< T, D >::operator*(), and vrpn::OwningPtr< T, D >::operator->().
#define VRPN_CURRENT_FUNCTION "(unknown)" |
Expands to the special preprocessor macro providing a useful description of the current function, where available.
Definition at line 87 of file vrpn_Assert.h.
#define VRPN_VERIFY | ( | expr | ) | VRPN_ASSERT(expr) |
Typically forwards to VRPN_ASSERT, but in cases where VRPN_ASSERT would expand to nothing (not evaluating the expression), VRPN_VERIFY evaluates the expression but discards the result.
Definition at line 172 of file vrpn_Assert.h.
#define VRPN_VERIFY_MSG | ( | expr, | |
msg ) VRPN_ASSERT_MSG(expr,msg) |
Like VRPN_VERIFY(expr) but allows specification of a message to be included in the case of a failed assertion.
Definition at line 173 of file vrpn_Assert.h.