ae2f_docs
Loading...
Searching...
No Matches
errGlob.h
Go to the documentation of this file.
1/**
2 * @file errGlob.h
3 * @author ae2f
4 * @brief
5 * Those numbers with [ @ref ae2f_err_t ] will be the state.
6 *
7 * @date 2025-02-01
8 *
9 * @copyright Copyright (c) 2025
10 */
11
12#if !defined(ae2f_errGlobal_h)
13#define ae2f_errGlobal_h
14
15#include "./c90/StdInt.h"
16
17/**
18 * @typedef ae2f_err_t
19 * @brief Least integer type to store the error value
20 * @see ae2f_errGlob
21 * */
22typedef uint_least8_t ae2f_err_t;
23
24
25/**
26 * @enum ae2f_errGlob
27 * */
28typedef enum {
29 /** @brief Success */
31
32 /** @brief Implementation not found (not expected) */
34
35 /** @brief Null Pointer Exception */
37
38 /** @brief Releasing, flushing, etc has been failed. */
40
41 /** @brief Allocation has failed. */
43
44 /** @brief Wrong Ooperation */
46
47 /** @brief Error for another reason, such as low level. (See another status value.) */
49
50 /** @brief Operation has finished. */
52 ae2f_errGlob_
53} ae2f_errGlob;
54
55
56
57/**
58 * @deprecated
59 *
60 * @brief
61 * Check if the state code is a critical error.
62 * @param n {ae2f_err_t} Error code
63 * @return If it is not zero, it is a critical error.
64 */
65#define ae2f_errGlobNormalised(n) (((n) & ae2f_errGlob_DONE_HOWEV) ? ae2f_errGlob_OK : (n))
66
67#endif
#define ae2f_CmpGetGt(a, b)
Definition Cmp.h:63
#define ae2f_CmpGetLs(a, b)
Definition Cmp.h:71
#define ae2f_constexprmethod
Definition Constexpr.h:56
#define ae2f_WhenCXX(a)
Appears when the current language is C.
Definition Cxx.h:44
#define ae2f_is_cxx
Definition Cxx.h:48
#define ae2f_WhenC(a)
Appears when the current language is C++.
Definition Cxx.h:38
#define ae2f_float
Predefined floating point type.
Definition Float.auto.h:11
#define ae2f_float_WIDTH
Definition Float.auto.h:15
#define ae2f_NONE
Definition Guide.h:11
#define ae2f_stdcc_v
Standard C++ version. .
Definition LangVer.h:34
#define __ae2f_stdcheck_CC(v)
Definition LangVer.h:50
#define ae2f_PackCount
Definition Num.auto.h:6
@ ae2f_errGlob_ALLOC_FAILED
Allocation has failed.
Definition errGlob.h:42
@ ae2f_errGlob_NFOUND
Error for another reason, such as low level. (See another status value.).
Definition errGlob.h:48
@ ae2f_errGlob_FLUSH_FAILED
Releasing, flushing, etc has been failed.
Definition errGlob.h:39
@ ae2f_errGlob_IMP_NOT_FOUND
Implementation not found (not expected).
Definition errGlob.h:33
@ ae2f_errGlob_OK
Success.
Definition errGlob.h:30
@ ae2f_errGlob_WRONG_OPERATION
Wrong Ooperation.
Definition errGlob.h:45
@ ae2f_errGlob_PTR_IS_NULL
Null Pointer Exception.
Definition errGlob.h:36
@ ae2f_errGlob_DONE_HOWEV
Operation has finished.
Definition errGlob.h:51
uint_least8_t ae2f_err_t
Least integer type to store the error value.
Definition errGlob.h:22