Skip to main content

__assert_fail

Function __assert_fail 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __assert_fail( func: *const c_char, file: *const c_char, line: c_int, cond: *const c_char, ) -> !
Expand description

See https://pubs.opengroup.org/onlinepubs/9799919799/functions/assert.html.

Writes information about the function that failed to stderr and calls abort().

§Implementation

assert() is defined as a C macro in cbindgen that checks for NDEBUG and if not found gets forwarded to this function call.

§Safety

func, file and cond are guaranteed to be non-empty and valid.