Github   Telegram
Loading...
Searching...
No Matches
Namespaces | Macros
assert.hpp File Reference

Assertion macros UASSERT, UASSERT_MSG, UINVARIANT. More...

#include <string_view>
+ Include dependency graph for assert.hpp:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  utils
 Utilities.
 

Macros

#define UASSERT_MSG(expr, msg)
 Assertion macro for that aborts execution in DEBUG builds with a message msg and does nothing in release builds. More...
 
#define UASSERT(expr)
 Assertion macro that aborts execution in DEBUG builds and does nothing in release builds. More...
 
#define UINVARIANT(condition, message)
 Asserts in debug builds, throws utils::InvariantError in release. More...
 

Detailed Description

Assertion macros UASSERT, UASSERT_MSG, UINVARIANT.

Definition in file assert.hpp.

Macro Definition Documentation

◆ UASSERT

#define UASSERT (   expr)

Assertion macro that aborts execution in DEBUG builds and does nothing in release builds.

Examples
samples/http_caching/http_caching.cpp.

Definition at line 49 of file assert.hpp.

◆ UASSERT_MSG

#define UASSERT_MSG (   expr,
  msg 
)

Assertion macro for that aborts execution in DEBUG builds with a message msg and does nothing in release builds.

Examples
samples/flatbuf_service/flatbuf_service.cpp.

Definition at line 36 of file assert.hpp.

◆ UINVARIANT

#define UINVARIANT (   condition,
  message 
)

Asserts in debug builds, throws utils::InvariantError in release.

Examples
postgresql/functional_tests/basic_chaos/postgres_service.cpp.

Definition at line 55 of file assert.hpp.