CBMC
|
Base class for exceptions thrown in the cprover project. More...
#include <c_errors.h>
Public Member Functions | |
virtual std::string | what () const |
A human readable description of what went wrong. More... | |
virtual | ~cprover_exception_baset ()=default |
virtual std::string | what () const |
A human readable description of what went wrong. More... | |
virtual | ~cprover_exception_baset ()=default |
Protected Member Functions | |
cprover_exception_baset (std::string reason) | |
This constructor is marked protected to ensure this class isn't used directly. More... | |
cprover_exception_baset (std::string reason) | |
This constructor is marked protected to ensure this class isn't used directly. More... | |
Protected Attributes | |
std::string | reason |
The reason this exception was generated. More... | |
Base class for exceptions thrown in the cprover project.
Intended to be used as a convenient way to have a "catch all and report errors" from application entry points. Note that the reason we use a custom base class as opposed to std::exception or one of its derivates to avoid them being accidentally caught by code expecting standard exceptions to be only thrown by the standard library.
Definition at line 63 of file c_errors.h.
|
virtualdefault |
|
inlineexplicitprotected |
This constructor is marked protected to ensure this class isn't used directly.
Deriving classes should be used to more precisely describe the problem that occurred.
Definition at line 76 of file c_errors.h.
|
virtualdefault |
|
inlineexplicitprotected |
This constructor is marked protected to ensure this class isn't used directly.
Deriving classes should be used to more precisely describe the problem that occurred.
Definition at line 37 of file exception_utils.h.
|
virtual |
A human readable description of what went wrong.
For readability, implementors should not add a leading or trailing newline to this description.
Reimplemented in invalid_source_file_exceptiont, incorrect_goto_program_exceptiont, invalid_command_line_argument_exceptiont, invalid_restriction_exceptiont, and invalid_function_contract_pair_exceptiont.
Definition at line 12 of file exception_utils.cpp.
|
virtual |
A human readable description of what went wrong.
For readability, implementors should not add a leading or trailing newline to this description.
Reimplemented in invalid_source_file_exceptiont, incorrect_goto_program_exceptiont, invalid_command_line_argument_exceptiont, invalid_restriction_exceptiont, and invalid_function_contract_pair_exceptiont.
|
protected |
The reason this exception was generated.
This is the string returned by what()
unless that method is overridden
Definition at line 83 of file c_errors.h.