Conditionally include backtraces in ROCPROFSYS_THROW based on verbosity (#272)

* Conditionally include backtraces in ROCPROFSYS_THROW based on verbosity

Modify ROCPROFSYS_THROW to only include backtraces when:
  debug mode is enabled, OR
  verbose level is >= 2, OR
  running in CI environment

* Fix formatting errors
Tento commit je obsažen v:
Sajina PK
2025-07-07 14:14:02 -04:00
odevzdal GitHub
rodič 4e5029221b
revize b0ff07b4fe
3 změnil soubory, kde provedl 16 přidání a 2 odebrání
+6
Zobrazit soubor
@@ -73,6 +73,12 @@ exception<Tp>::exception(const char* _msg)
, m_what{ get_backtrace(_msg) }
{}
template <typename Tp>
exception<Tp>::exception(const std::string& _msg, bool with_backtrace)
: Tp{ _msg }
, m_what{ with_backtrace ? get_backtrace(_msg) : strdup(_msg.c_str()) }
{}
template <typename Tp>
exception<Tp>::~exception()
{