mirror of
https://github.com/gabime/spdlog.git
synced 2025-09-28 17:19:34 +08:00
Enabled bin_to_hex utest for stdformat, fixed std::formatter (#3315)
* Enabled bin_to_hex utest for stdformat, and fixed std::formatter * fixed usage of \ in macos.yml * explicitly cast diff variable in test_sink * moved from ::iterator to decltype * added fix for custom callbacks --------- Co-authored-by: Jan Koniarik <veverak@Jans-MacBook-Pro.local>
This commit is contained in:
@@ -16,7 +16,8 @@ TEST_CASE("custom_callback_logger", "[custom_callback_logger]") {
|
||||
spdlog::memory_buf_t formatted;
|
||||
formatter.format(msg, formatted);
|
||||
auto eol_len = strlen(spdlog::details::os::default_eol);
|
||||
lines.emplace_back(formatted.begin(), formatted.end() - eol_len);
|
||||
using diff_t = typename std::iterator_traits<decltype(formatted.end())>::difference_type;
|
||||
lines.emplace_back(formatted.begin(), formatted.end() - static_cast<diff_t>(eol_len));
|
||||
});
|
||||
std::shared_ptr<spdlog::sinks::test_sink_st> test_sink(new spdlog::sinks::test_sink_st);
|
||||
|
||||
|
Reference in New Issue
Block a user