diff --git a/CHANGELOG.md b/CHANGELOG.md index 7240869d..e1f9f06a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -71,6 +71,8 @@ the terminal while the logger is running. ([#395](https://github.com/odygrd/quill/issues/395)) - Ensure that after a logger is removed, there are no subsequent calls to the Handler's flush() or run_loop(), provided the Handler is not shared. ([#395](https://github.com/odygrd/quill/issues/395)) +- Ignore the virtual destructor missing warning for the `CustomTags` + class. ([#402](https://github.com/odygrd/quill/pull/402)) - Update bundled `libfmt` to `v10.2.1` ## v3.6.0 diff --git a/quill/include/quill/detail/misc/Common.h b/quill/include/quill/detail/misc/Common.h index 726db210..36f7975e 100644 --- a/quill/include/quill/detail/misc/Common.h +++ b/quill/include/quill/detail/misc/Common.h @@ -208,6 +208,17 @@ enum TimestampClockType : uint8_t Custom }; +#if defined(__clang__) + #pragma clang diagnostic push + #pragma clang diagnostic ignored "-Wnon-virtual-dtor" +#elif defined(__GNUC__) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wnon-virtual-dtor" +#elif defined(_WIN32) + #pragma warning(push) + #pragma warning(disable : 4265) // Disable warning about non-virtual destructor in MSVC +#endif + /** * CustomTags class that can be used for _WITH_TAGS log macros */ @@ -218,6 +229,14 @@ class CustomTags virtual void format(std::string&) const = 0; }; +#if defined(__clang__) + #pragma clang diagnostic pop +#elif defined(__GNUC__) + #pragma GCC diagnostic pop +#elif defined(_WIN32) + #pragma warning(pop) +#endif + /** * backend worker thread error handler type */