| 1 | #ifndef UTILS_HEADER |
| 2 | #define UTILS_HEADER |
| 3 | |
| 4 | #include <cgreen/filename.h> |
| 5 | #include <stdbool.h> |
| 6 | |
| 7 | #ifdef __cplusplus |
| 8 | namespace cgreen { |
| 9 | extern "C" { |
| 10 | #endif |
| 11 | |
| 12 | extern bool panic_use_colours; |
| 13 | |
| 14 | #define PANIC(...) panic(FILENAME, __LINE__, __VA_ARGS__) |
| 15 | extern char *string_dup(const char *original); |
| 16 | extern void panic_set_output_buffer(const char *buffer); |
| 17 | extern void panic(const char *filename, int line, const char *fmt, ...); |
| 18 | |
| 19 | #ifdef __cplusplus |
| 20 | } |
| 21 | } |
| 22 | #endif |
| 23 | |
| 24 | #endif |