You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
32 lines
474 B
32 lines
474 B
#pragma once
|
|
|
|
#ifdef __cplusplus
|
|
namespace cmkr::error {
|
|
|
|
struct Status {
|
|
enum class Code {
|
|
Success = 0,
|
|
RuntimeError,
|
|
InitError,
|
|
GenerationError,
|
|
BuildError,
|
|
};
|
|
Status(Code ec) noexcept;
|
|
operator int() const noexcept;
|
|
Code code() const noexcept;
|
|
|
|
private:
|
|
Code ec_ = Code::Success;
|
|
};
|
|
|
|
} // namespace cmkr::error
|
|
|
|
extern "C" {
|
|
#endif
|
|
|
|
const char *cmkr_error_status_string(int);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|