libjmmcg
build_2783
A C++ library containing an eclectic mix of useful, advanced components.
|
A nice enum for the exit codes from main(). More...
#include <exit_codes.hpp>
Public Types | |
enum | codes : std::uint8_t { exit_success =EXIT_SUCCESS, exit_unknown_failure =EXIT_FAILURE, exit_unknown_exception =129, exit_stl_exception, exit_jmmcg_exception, exit_crt_exception, exit_parameter_error, exit_print_help, exit_print_version } |
Static Public Member Functions | |
static std::string | to_string (codes e) noexcept(false) |
static std::string | to_string () noexcept(false) |
A nice enum for the exit codes from main().
Note use of POSIX compatibility macros & starting our custom errors at 129. Also note that we shouldn't exceed 255, as the exit code is truncated to 8 bits, which would cause problems...
Definition at line 56 of file exit_codes.hpp.
enum jmmcg::exit_codes::codes : std::uint8_t |
Enumerator | |
---|---|
exit_success | |
exit_unknown_failure | |
exit_unknown_exception | |
exit_stl_exception | |
exit_jmmcg_exception | |
exit_crt_exception | |
exit_parameter_error | |
exit_print_help | |
exit_print_version |
Definition at line 75 of file exit_codes.hpp.
|
inlinestaticnoexcept |
Definition at line 82 of file exit_codes_impl.hpp.
|
inlinestaticnoexcept |
Definition at line 77 of file exit_codes_impl.hpp.