From 86e27ccb41c2708e17ba264359223ef664d9bb78 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Tue, 12 Apr 2022 09:30:29 -0700 Subject: [PATCH] Suppress a warning --- include/fmt/ostream.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/fmt/ostream.h b/include/fmt/ostream.h index b77bd9a7a984..e228cfc6f983 100644 --- a/include/fmt/ostream.h +++ b/include/fmt/ostream.h @@ -93,7 +93,7 @@ inline bool write(std::wfilebuf&, fmt::basic_string_view) { // It is a separate function rather than a part of vprint to simplify testing. template void write_buffer(std::basic_ostream& os, buffer& buf) { - if (FMT_MSC_VER) { + if (const_check(FMT_MSC_VER)) { auto filebuf = dynamic_cast*>(os.rdbuf()); if (filebuf && write(*filebuf, {buf.data(), buf.size()})) return; }