The manual
ginnOS
The reference: libc, the libraries and the kernel
Loading...
Searching...
No Matches
assert.h
Go to the documentation of this file.
1#pragma once
2
3/**
4 * @file assert.h
5 * @brief assert(): with NDEBUG defined it checks nothing.
6 */
7
8void __assert_fail(const char *expression, const char *file, int line, const char *function)
9 __attribute__((noreturn));
10
11#ifdef NDEBUG
12#define assert(expression) ((void)0)
13#else
14#define assert(expression) \
15 ((expression) ? (void)0 : __assert_fail(#expression, __FILE__, __LINE__, __func__))
16#endif
void __assert_fail(const char *expression, const char *file, int line, const char *function) __attribute__((noreturn))
ELF32 file header.
Definition elf.h:51
an open-file description.
Definition file.h:64