Added const qualifier to bin_hex_formatter to support c++20

This commit is contained in:
Gabi Melman 2023-07-04 17:53:04 +03:00 committed by GitHub
parent 3cd06a3d40
commit 8b8bc20f30
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -156,7 +156,7 @@ struct formatter<spdlog::details::dump_info<T>, char>
// format the given bytes range as hex
template<typename FormatContext, typename Container>
auto format(const spdlog::details::dump_info<Container> &the_range, FormatContext &ctx) -> decltype(ctx.out())
auto format(const spdlog::details::dump_info<Container> &the_range, FormatContext &ctx) const -> decltype(ctx.out())
{
SPDLOG_CONSTEXPR const char *hex_upper = "0123456789ABCDEF";
SPDLOG_CONSTEXPR const char *hex_lower = "0123456789abcdef";