diff --git a/include/spdlog/common.h b/include/spdlog/common.h index 51c5195c..3bd30879 100644 --- a/include/spdlog/common.h +++ b/include/spdlog/common.h @@ -166,16 +166,6 @@ using filename_t = std::wstring; using filename_t = std::string; #endif -#define SPDLOG_CATCH_AND_HANDLE \ - catch (const std::exception &ex) \ - { \ - err_handler_(ex.what()); \ - } \ - catch (...) \ - { \ - err_handler_("Unknown exeption in logger"); \ - } - namespace details { // make_unique support for pre c++14 diff --git a/include/spdlog/details/logger_impl.h b/include/spdlog/details/logger_impl.h index 850f8639..eb5fcdef 100644 --- a/include/spdlog/details/logger_impl.h +++ b/include/spdlog/details/logger_impl.h @@ -10,6 +10,16 @@ #include #include +#define SPDLOG_CATCH_AND_HANDLE \ + catch (const std::exception &ex) \ + { \ + err_handler_(ex.what()); \ + } \ + catch (...) \ + { \ + err_handler_("Unknown exeption in logger"); \ + } + // create logger with given name, sinks and the default pattern formatter // all other ctors will call this one template