#ifndef SNUVI_ERROR_H #define SNUVI_ERROR_H #ifdef __cplusplus extern "C" { #endif #include #include #include "Check.h" typedef struct Error { int line; int codeLine; char message[256]; char paths[256]; } Error; check_format(5, 6) void eInitError(Error* e, const char* path, int line, int codeLine, const char* format, ...); void eInitErrorV(Error* e, const char* path, int codeLine, int line, const char* format, va_list ap); void eInitSuccess(Error* e); void eAddPath(Error* e, const char* path); bool eHasError(const Error* e); #ifdef __cplusplus } #endif #endif