BarryServer : Git

All the code for all my projects
// BarryServer : Git / Nucleus / blob / b5be0ef94a970c5fba447e74f4b194428d9cd61d / include / nucleus / panic.h

// Related

Nucleus

Barry Better logging/panic routines 7cbafe8 (3 years, 3 months ago)
#ifndef _NUCLEUS_PANIC_H
#define _NUCLEUS_PANIC_H

void kprintf(char *fmt, ...);
_Noreturn void panic(char *fmt, ...);

#define ASSERT(c) ({ \
	if (__builtin_expect(!(c),0)) \
		panic("Assertion failed (%s:%d): %s", \
		      __FILE__, __LINE__, #c); \
	c; \
})

#endif