-
Notifications
You must be signed in to change notification settings - Fork 4.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#define SPDLOG_LEVEL_NAMES with external FMT doesn't compile, starting from libfmt11. #3233
Comments
This is working, and at least is a better work-around IMO: #include <string_view>
using namespace std::string_view_literals;
#define SPDLOG_LEVEL_NAMES { "TRACE"sv, "DEBUG"sv, "INFO"sv, "NOTICE"sv, "WARNING"sv, "ERROR"sv, "OFF"sv } |
PR is welcome. Note that the “sv” literal is c++17 while spdlog should support 11 |
I would open a PR, but I don't really know what the best approach is for the majority of people. |
I was thinking again on this and realized that this would likely not really be an issue, because the problem only presents when So, most likely for now at least the only thing you really need to change is documenting this option, which could likely be done in the same |
This came up macOS/apple clang:
Removing the
constexpr
fromstatic string_view_t level_string_views[] SPDLOG_LEVEL_NAMES;
makes it compile, but I don't think this is really the correct fix?The text was updated successfully, but these errors were encountered: