41#if defined(_MSC_VER) && !defined(SC_WIN_DLL_WARN)
43# pragma warning(disable:4275)
108class sc_report_handler;
132 const
char * get_msg_type() const;
134 const
char * get_msg()
const
147 {
return *timestamp; }
155 virtual const char*
what() const noexcept
202#define SC_REPORT_INFO( msg_type, msg ) \
203 SC_REPORT_INFO_VERB( msg_type, msg, ::sc_core::SC_MEDIUM )
205#define SC_REPORT_INFO_VERB( msg_type, msg, verbosity ) \
207 if( verbosity <= ::sc_core::sc_report_handler::get_verbosity_level() ) \
208 ::sc_core::sc_report_handler::report( \
209 ::sc_core::SC_INFO, msg_type, msg, verbosity, __FILE__ , __LINE__ \
213#define SC_REPORT_WARNING( msg_type, msg ) \
214 ::sc_core::sc_report_handler::report( \
215 ::sc_core::SC_WARNING, msg_type, msg, __FILE__, __LINE__ )
217#define SC_REPORT_ERROR( msg_type, msg ) \
218 ::sc_core::sc_report_handler::report( \
219 ::sc_core::SC_ERROR, msg_type, msg, __FILE__, __LINE__ )
221#define SC_REPORT_FATAL( msg_type, msg ) \
222 ::sc_core::sc_report_handler::report( \
223 ::sc_core::SC_FATAL, msg_type, msg, __FILE__, __LINE__ )
241#if defined(NDEBUG) && !defined(SC_ENABLE_ASSERTIONS)
243#define sc_assert(expr) \
248#define sc_assert(expr) \
249 ((void)((expr) ? 0 : \
250 (::sc_core::sc_assertion_failed(#expr,__FILE__,__LINE__),0)))
270#if defined(_MSC_VER) && !defined(SC_WIN_DLL_WARN)
SC_API const char SC_ID_ABORT_[]
SC_API const char SC_ID_OUT_OF_BOUNDS_[]
SC_API const std::string sc_report_compose_message(const sc_report &)
SC_API const char SC_ID_INTERNAL_ERROR_[]
@ SC_DEFAULT_CATCH_ACTIONS
@ SC_DEFAULT_ERROR_ACTIONS
@ SC_DEFAULT_INFO_ACTIONS
@ SC_DEFAULT_WARNING_ACTIONS
@ SC_DEFAULT_FATAL_ACTIONS
std::exception sc_exception
SC_API const char SC_ID_REGISTER_ID_FAILED_[]
SC_API const char SC_ID_ASSERTION_FAILED_[]
SC_API const char SC_ID_WITHOUT_MESSAGE_[]
SC_API void sc_assertion_failed(const char *msg, const char *file, int line)
SC_API const char SC_ID_NOT_IMPLEMENTED_[]
SC_API const char SC_ID_UNKNOWN_ERROR_[]
static void suppress_warnings(bool)
static void suppress_id(int id, bool)
static void make_warnings_errors(bool)
static void register_id(int id, const char *msg)
sc_report(sc_severity, const sc_msg_def *, const char *msg, const char *file, int line, int verbosity_level=SC_MEDIUM)
sc_report(const sc_report &)
int get_line_number() const
static void suppress_infos(bool)
const char * get_process_name() const
sc_report & operator=(const sc_report &)
static bool is_suppressed(int id)
const sc_time & get_time() const
virtual const char * what() const noexcept
virtual ~sc_report() noexcept
sc_severity get_severity() const
const char * get_file_name() const
friend SC_API sc_report * sc_handle_exception()
static const char * get_message(int id)
int get_verbosity() const