#include "error.h"
Public Member Functions | |
error_system (interpreter &interp) | |
~error_system ()=default | |
bool | backtrace_on_warning () const |
bool | backtrace_on_warning (bool flag) |
octave_value | backtrace_on_warning (const octave_value_list &args, int nargout) |
bool | beep_on_error () const |
bool | beep_on_error (bool flag) |
octave_value | beep_on_error (const octave_value_list &args, int nargout) |
bool | debug_on_caught () const |
bool | debug_on_caught (bool flag) |
octave_value | debug_on_caught (const octave_value_list &args, int nargout) |
bool | debug_on_error () const |
bool | debug_on_error (bool flag) |
octave_value | debug_on_error (const octave_value_list &args, int nargout) |
bool | debug_on_warning () const |
bool | debug_on_warning (bool flag) |
octave_value | debug_on_warning (const octave_value_list &args, int nargout) |
std::string | default_warning_state () |
void | disable_warning (const std::string &id) |
bool | discard_warning_messages () const |
bool | discard_warning_messages (bool flag) |
octave_value | discard_warning_messages (const octave_value_list &args, int nargout) |
void | display_exception (const execution_exception &ee) const |
void | display_warning_options (std::ostream &os) |
OCTAVE_NORETURN void | error_1 (const char *id, const char *fmt, va_list args) |
OCTAVE_NORETURN void | error_1 (execution_exception &ee, const char *id, const char *fmt, va_list args) |
void | initialize_default_warning_state () |
void | interpreter_try (unwind_protect &frame) |
std::string | last_error_id () const |
octave_value | last_error_id (const octave_value_list &args, int nargout) |
std::string | last_error_id (const std::string &s) |
std::string | last_error_message () const |
octave_value | last_error_message (const octave_value_list &args, int nargout) |
std::string | last_error_message (const std::string &s) |
octave_map | last_error_stack () const |
octave_map | last_error_stack (const octave_map &new_val) |
std::string | last_warning_id () const |
octave_value | last_warning_id (const octave_value_list &args, int nargout) |
std::string | last_warning_id (const std::string &s) |
std::string | last_warning_message () const |
octave_value | last_warning_message (const octave_value_list &args, int nargout) |
std::string | last_warning_message (const std::string &s) |
OCTAVE_NORETURN void | panic (const char *fmt,...) |
bool | quiet_warning () const |
bool | quiet_warning (bool flag) |
octave_value | quiet_warning (const octave_value_list &args, int nargout) |
OCTAVE_NORETURN void | rethrow_error (const std::string &id, const std::string &msg, const octave_map &stack) |
void | save_exception (const execution_exception &ee) |
void | set_backtrace_on_warning (bool flag) |
void | set_beep_on_error (bool flag) |
void | set_debug_on_caught (bool flag) |
void | set_debug_on_error (bool flag) |
void | set_debug_on_warning (bool flag) |
void | set_discard_warning_messages (bool flag) |
void | set_last_error_id (const std::string &val) |
void | set_last_error_message (const std::string &val) |
void | set_last_error_stack (const octave_map &val) |
void | set_last_warning_id (const std::string &val) |
void | set_last_warning_message (const std::string &val) |
void | set_quiet_warning (bool flag) |
void | set_verbose_warning (bool flag) |
void | set_warning_option (const std::string &state, const std::string &id) |
void | set_warning_options (const octave_map &val) |
OCTAVE_NORETURN void | throw_error (const std::string &err_type, const std::string &id, const std::string &message, const std::list< frame_info > &stack_info=std::list< frame_info >()) |
OCTAVE_NORETURN void | throw_error (execution_exception &ee) |
bool | verbose_warning () const |
bool | verbose_warning (bool flag) |
octave_value | verbose_warning (const octave_value_list &args, int nargout) |
void | verror (bool save_last_error, std::ostream &os, const char *name, const char *id, const char *fmt, va_list args, bool with_cfn=false) |
OCTAVE_NORETURN void | vpanic (const char *fmt, va_list args) |
OCTAVE_NORETURN void | vusage (const char *id, const char *fmt, va_list args) |
void | vwarning (const char *id, const char *fmt, va_list args) |
void | vwarning (const char *name, const char *id, const char *fmt, va_list args) |
int | warning_enabled (const std::string &id) |
For given warning ID, return 0 if warnings are disabled, 1 if enabled, and 2 if the given ID should be an error instead of a warning. More... | |
octave_map | warning_options () const |
octave_map | warning_options (const octave_map &new_val) |
octave_scalar_map | warning_query (const std::string &id_arg) |
Static Public Member Functions | |
static std::list< frame_info > | make_stack_frame_list (const octave_map &stack) |
static octave_map | make_stack_map (const std::list< frame_info > &frames) |
error_system::error_system | ( | interpreter & | interp | ) |
|
default |
octave_value error_system::backtrace_on_warning | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 314 of file error.cc.
References octave::set_internal_variable().
octave_value error_system::beep_on_error | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 307 of file error.cc.
References octave::set_internal_variable().
octave_value error_system::debug_on_caught | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 285 of file error.cc.
References octave::set_internal_variable().
Referenced by bp_table::dbclear_all_signals(), bp_table::dbstop_process_map_args(), bp_table::stop_on_err_warn_status(), and tree_evaluator::visit_statement().
octave_value error_system::debug_on_error | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 278 of file error.cc.
References octave::set_internal_variable().
Referenced by bp_table::dbclear_all_signals(), bp_table::dbstop_process_map_args(), tree_evaluator::enter_debugger(), bp_table::stop_on_err_warn_status(), and tree_evaluator::visit_statement().
octave_value error_system::debug_on_warning | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 292 of file error.cc.
References octave::set_internal_variable().
Referenced by bp_table::dbclear_all_signals(), bp_table::dbstop_process_map_args(), tree_evaluator::enter_debugger(), and bp_table::stop_on_err_warn_status().
std::string error_system::default_warning_state | ( | ) |
Definition at line 711 of file error.cc.
References octave_map::contents(), and warning_options().
void error_system::disable_warning | ( | const std::string & | id | ) |
Definition at line 841 of file error.cc.
References set_warning_option().
|
inline |
|
inline |
octave_value error_system::discard_warning_messages | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 299 of file error.cc.
References octave::set_internal_variable().
Referenced by base_parser::finish_array_list(), and base_parser::make_colon_expression().
void error_system::display_exception | ( | const execution_exception & | ee | ) | const |
Definition at line 924 of file error.cc.
References event_manager::display_exception(), interpreter::get_event_manager(), and octave_diary.
Referenced by interpreter::handle_exception(), tree_evaluator::repl(), tree_evaluator::server_loop(), and tree_evaluator::visit_statement().
void error_system::display_warning_options | ( | std::ostream & | os | ) |
Definition at line 735 of file error.cc.
References octave_map::contents(), and warning_options().
void error_system::error_1 | ( | const char * | id, |
const char * | fmt, | ||
va_list | args | ||
) |
void error_system::error_1 | ( | execution_exception & | ee, |
const char * | id, | ||
const char * | fmt, | ||
va_list | args | ||
) |
Definition at line 568 of file error.cc.
Referenced by vwarning().
void error_system::initialize_default_warning_state | ( | ) |
Definition at line 847 of file error.cc.
References warning_options().
void error_system::interpreter_try | ( | unwind_protect & | frame | ) |
Definition at line 868 of file error.cc.
References action_container::protect_var().
|
inline |
Definition at line 236 of file error.h.
Referenced by save_exception().
octave_value error_system::last_error_id | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 358 of file error.cc.
References octave::set_internal_variable().
Referenced by tree_evaluator::visit_statement(), and tree_evaluator::visit_try_catch_command().
|
inline |
|
inline |
Definition at line 191 of file error.h.
Referenced by save_exception().
octave_value error_system::last_error_message | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 336 of file error.cc.
References octave::set_internal_variable().
Referenced by tree_evaluator::visit_try_catch_command().
|
inline |
|
inline |
Definition at line 250 of file error.h.
Referenced by save_exception(), and tree_evaluator::visit_try_catch_command().
|
inline |
|
inline |
Definition at line 222 of file error.h.
Referenced by warning_query().
octave_value error_system::last_warning_id | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 351 of file error.cc.
References octave::set_internal_variable().
|
inline |
|
inline |
octave_value error_system::last_warning_message | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 343 of file error.cc.
References octave::set_internal_variable().
Referenced by base_parser::finish_array_list(), and base_parser::make_colon_expression().
|
inline |
|
static |
Definition at line 399 of file error.cc.
References octave_map::contents(), and Array< T, Alloc >::numel().
Referenced by Ferror(), and rethrow_error().
|
static |
Definition at line 372 of file error.cc.
Referenced by save_exception().
void error_system::panic | ( | const char * | fmt, |
... | |||
) |
octave_value error_system::quiet_warning | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 329 of file error.cc.
References octave::set_internal_variable().
void error_system::rethrow_error | ( | const std::string & | id, |
const std::string & | msg, | ||
const octave_map & | stack | ||
) |
Definition at line 604 of file error.cc.
References octave_map::contains(), error(), octave_map::isempty(), make_stack_frame_list(), octave_map::setfield(), and throw_error().
void error_system::save_exception | ( | const execution_exception & | ee | ) |
Definition at line 912 of file error.cc.
References last_error_id(), last_error_message(), last_error_stack(), make_stack_map(), and message().
Referenced by tree_evaluator::do_unwind_protect_cleanup_code(), tree_evaluator::eval(), tree_evaluator::evalin(), interpreter::handle_exception(), tree_evaluator::repl(), tree_evaluator::server_loop(), tree_evaluator::visit_statement(), tree_evaluator::visit_try_catch_command(), and tree_evaluator::visit_unwind_protect_command().
|
inline |
|
inline |
Definition at line 58 of file error.h.
Referenced by tree_evaluator::enter_debugger().
|
inline |
Definition at line 86 of file error.h.
Referenced by tree_evaluator::enter_debugger().
|
inline |
Definition at line 100 of file error.h.
Referenced by base_parser::finish_array_list(), and base_parser::make_colon_expression().
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 203 of file error.h.
Referenced by base_parser::finish_array_list(), and base_parser::make_colon_expression().
void error_system::set_warning_option | ( | const std::string & | state, |
const std::string & | id | ||
) |
Definition at line 776 of file error.cc.
Referenced by disable_warning().
|
inline |
void error_system::throw_error | ( | const std::string & | err_type, |
const std::string & | id, | ||
const std::string & | message, | ||
const std::list< frame_info > & | stack_info = std::list<frame_info> () |
||
) |
Definition at line 881 of file error.cc.
References tree_evaluator::backtrace_info(), interpreter::get_evaluator(), and message().
Referenced by rethrow_error().
void error_system::throw_error | ( | execution_exception & | ee | ) |
octave_value error_system::verbose_warning | ( | const octave_value_list & | args, |
int | nargout | ||
) |
Definition at line 322 of file error.cc.
References octave::set_internal_variable().
void error_system::verror | ( | bool | save_last_error, |
std::ostream & | os, | ||
const char * | name, | ||
const char * | id, | ||
const char * | fmt, | ||
va_list | args, | ||
bool | with_cfn = false |
||
) |
void error_system::vpanic | ( | const char * | fmt, |
va_list | args | ||
) |
void error_system::vusage | ( | const char * | id, |
const char * | fmt, | ||
va_list | args | ||
) |
void error_system::vwarning | ( | const char * | id, |
const char * | fmt, | ||
va_list | args | ||
) |
Definition at line 589 of file error.cc.
References error_1(), vwarning(), and warning_enabled().
void error_system::vwarning | ( | const char * | name, |
const char * | id, | ||
const char * | fmt, | ||
va_list | args | ||
) |
int error_system::warning_enabled | ( | const std::string & | id | ) |
For given warning ID, return 0 if warnings are disabled, 1 if enabled, and 2 if the given ID should be an error instead of a warning.
Definition at line 424 of file error.cc.
References octave_map::contents(), octave_map::numel(), and warning_options().
Referenced by vwarning().
|
inline |
Definition at line 173 of file error.h.
Referenced by default_warning_state(), display_warning_options(), initialize_default_warning_state(), warning_enabled(), and warning_query().
|
inline |
octave_scalar_map error_system::warning_query | ( | const std::string & | id_arg | ) |
Definition at line 654 of file error.cc.
References octave_map::contents(), last_warning_id(), and warning_options().