35#ifndef LIBTCOD_ERROR_H_
36#define LIBTCOD_ERROR_H_
124#define TCOD_set_errorv(msg) TCOD_set_errorf("%s:%i\n%s", TCOD_STRVERSIONNAME " " __FILE__, __LINE__, (msg))
130#define TCOD_set_errorvf(fmt, ...) \
131 TCOD_set_errorf("%s:%i\n" fmt, TCOD_STRVERSIONNAME " " __FILE__, __LINE__, __VA_ARGS__)
TCOD_Error
An enum of libtcod error codes.
Definition error.h:48
@ TCOD_E_WARN
The function completed, but a minor issue was detected.
Definition error.h:82
@ TCOD_E_REQUIRES_ATTENTION
This function needs additional attention, but is otherwise functioning correctly.
Definition error.h:78
@ TCOD_E_OUT_OF_MEMORY
The function failed because it was unable to allocate enough memory.
Definition error.h:70
@ TCOD_E_INVALID_ARGUMENT
The function failed because a given input argument was invalid.
Definition error.h:66
@ TCOD_E_OK
The function completed successfully without issues.
Definition error.h:55
@ TCOD_E_ERROR
The error code for generic runtime errors.
Definition error.h:62
TCOD_Error TCOD_set_error(const char *msg)
Set an error message and return TCOD_E_ERROR.
TCOD_Error TCOD_set_errorf(const char *fmt,...)
Set an error message and return TCOD_E_ERROR.
const char * TCOD_get_error(void)
Return the last error message.
void TCOD_clear_error(void)
Clear a current existing error message.
Libtcod version informaiton.