Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Compatibility with external fmtlib 11.1.1 (#3312)
Include fmtlib's `xchar` header to include `fmt::basic_format_string`. Otherwise, compilation with an external fmtlib 11.1.1 fails with ``` In file included from include/spdlog/spdlog.h:12: include/spdlog/common.h:369:49: error: no template named 'basic_format_string' in namespace 'fmt'; did you mean 'std::basic_format_string'? 369 | inline fmt::basic_string_view<T> to_string_view(fmt::basic_format_string<T, Args...> fmt) { | ^~~~~ ``` Signed-off-by: Christian Blichmann <cblichmann@google.com>
- Loading branch information
7f8060d
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this really needed?
The
basic_format_string
issue was already fixed with parent commit (276ee5f) and including fmt/xchar.h when wchar_t support is not needed was previously declared as unwanted (#3277 (comment)).Including this file is causing compilation errors on one of gcc toolchains I have to use (probably due to a bug in the toolchain), that I'd rather avoid dealing with if not necessary.
7f8060d
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes might be unneeded. PR is welcome