|
LibJuno 1.0.1
LibJuno is a lightweight C11 library designed specifically for embedded systems.
|
Functions | |
| JUNO_MODULE_RESULT (JUNO_RESULT_BOOL_T, bool) | |
| Result type carrying a bool payload. | |
| JUNO_MODULE_RESULT (JUNO_RESULT_UINT32_T, uint32_t) | |
| Result type carrying a 32-bit unsigned integer payload. | |
| JUNO_MODULE_RESULT (JUNO_RESULT_F64_T, double) | |
| Result type carrying a double-precision floating-point payload. | |
| JUNO_MODULE_RESULT (JUNO_RESULT_SIZE_T, size_t) | |
| Result type carrying a size_t payload. | |
| JUNO_MODULE_RESULT (JUNO_RESULT_VOID_PTR_T, void *) | |
| Result type carrying a void* payload. | |
This header provides convenience specializations of the generic JUNO_MODULE_RESULT(NAME_T, OK_T) macro for frequently used payload types. These result types are used to return a status alongside a typed value in a single aggregate, promoting deterministic error handling without exceptions.
Usage example:
| JUNO_MODULE_RESULT | ( | JUNO_RESULT_BOOL_T | , |
| bool | |||
| ) |
Result type carrying a bool payload.
| JUNO_MODULE_RESULT | ( | JUNO_RESULT_F64_T | , |
| double | |||
| ) |
Result type carrying a double-precision floating-point payload.
| JUNO_MODULE_RESULT | ( | JUNO_RESULT_SIZE_T | , |
| size_t | |||
| ) |
Result type carrying a size_t payload.
| JUNO_MODULE_RESULT | ( | JUNO_RESULT_UINT32_T | , |
| uint32_t | |||
| ) |
Result type carrying a 32-bit unsigned integer payload.
| JUNO_MODULE_RESULT | ( | JUNO_RESULT_VOID_PTR_T | , |
| void * | |||
| ) |
Result type carrying a void* payload.