yahelpers
Enhanced debugging functionality for the ya ecosystem
Loading...
Searching...
No Matches
Macros
assert.h File Reference

Assertion utilities for the ya ecosystem. More...

#include "log.h"
#include <stdlib.h>
#include <time.h>
#include <assert.h>
Include dependency graph for assert.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define ASSERT_DEFAULT   0
 Print timestamp of the assert and abort on error.
 
#define ASSERT_NO_ABORT   1
 Specifies whether the assert will abort on error.
 
#define ASSERT_NO_TIMESTAMP   2
 Specifies whether the assert will print a timestamp on error.
 
#define ASSERT_FOR_TESTS   4
 Specifies whether the assert is CMocka-compatible.
 
#define ASSERT(cond, opts)
 Prints a debug message if the condition cond is failed.
 

Detailed Description

Assertion utilities for the ya ecosystem.

Author
asaeppel4231
Version
0.1

This header provides lightweight assertion helpers used throughout the ya ecosystem. Assertions help detect incorrect assumptions and unexpected states during runtime.

When NDEBUG is defined, all assertions are disabled.