46 lines
1.3 KiB
C
46 lines
1.3 KiB
C
/**
|
|
* @file RSPTerrain_errordefs.h
|
|
* @date 22/08/2022
|
|
* @author JackCarterSmith
|
|
* @copyright GPL-v3.0
|
|
* @brief Errors type definition file. Used mostly by methods in this project.
|
|
*
|
|
*/
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
|
#ifndef RSPLIB_ERRORS_H_
|
|
#define RSPLIB_ERRORS_H_
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
// Errors types definitions
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
#ifndef NO_ERROR
|
|
#define NO_ERROR 0 // In case of dual declaration by GCC
|
|
#endif
|
|
#define RSPLIB_SUCCESS NO_ERROR //!< All is running good!
|
|
|
|
#define RSPLIB_ERROR_GENERIC 1 //!< Misuse of the program
|
|
#define RSPLIB_ERROR_MEMORY 2 //!< Memory de/allocation failure
|
|
#define RSPLIB_ERROR_IO 3 //!< File system access failure
|
|
#define RSPLIB_ERROR_PROCESS 4 //!< Internal processing failure
|
|
|
|
#define RSPLIB_ERROR_ARGS_NULL 16 //!< Method not NULL input expected
|
|
#define RSPLIB_ERROR_ARGS_RANGE 17 //!< Method input out of expected range
|
|
|
|
#define RSPLIB_ERROR_MOD_DISABLED 64 //!< A necessary module hasn't been activated during compilation time
|
|
|
|
#define RSPLIB_ERROR_REALITY_BRK -1 //!< This error can only appear in alternate reality
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* RSPLIB_ERRORS_H_ */
|