From 9ec020592a2df91daab38405860eadaf5c332ada Mon Sep 17 00:00:00 2001 From: Bernd Baumanns Date: Thu, 24 Sep 2020 17:27:52 +0200 Subject: [PATCH] remove dependency to windows.h --- include/fmt/format-inl.h | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/include/fmt/format-inl.h b/include/fmt/format-inl.h index ee5ac889..b1882dc5 100644 --- a/include/fmt/format-inl.h +++ b/include/fmt/format-inl.h @@ -23,16 +23,15 @@ #endif #ifdef _WIN32 -# if defined(FMT_BIG_WIN) || defined(NOMINMAX) -# include -# else -# define NOMINMAX -# define WIN32_LEAN_AND_MEAN -# include -# undef WIN32_LEAN_AND_MEAN -# undef NOMINMAX -# endif # include +FMT_BEGIN_NAMESPACE + using DWORD = uint32_t; + using HANDLE = void*; + + extern "C" { + int __stdcall WriteConsoleW(void* hConsoleOutput, const void* lpBuffer, uint32_t nNumberOfCharsToWrite, uint32_t* lpNumberOfCharsWritten, void* lpReserved); + } +FMT_END_NAMESPACE #endif // Dummy implementations of strerror_r and strerror_s called if corresponding