error.cpp¶
src/types/error.cpp
@file error.cpp @brief Error type implementations for librentropic-types.
Owners: @tvanfossen
entropic_error_name
const char * entropic_error_name(entropic_error_t code)
Get the human-readable name for an error code.
src/types/error.cpp:87
Source · 4 lines
extern "C" const char* entropic_error_name(entropic_error_t code) {
int idx = static_cast<int>(code);
return (idx >= 0 && idx < s_error_count) ? s_error_names[idx] : "ENTROPIC_ERROR_UNKNOWN";
}Activity · 2 steps
ENTROPIC_EXPORT const char * entropic_error_name(entropic_error_t code)
Get the human-readable name for an error code.
src/types/error.cpp:87
Source · 4 lines
extern "C" const char* entropic_error_name(entropic_error_t code) {
int idx = static_cast<int>(code);
return (idx >= 0 && idx < s_error_count) ? s_error_names[idx] : "ENTROPIC_ERROR_UNKNOWN";
}