Avoid inclusion of rarely used Windows SDK headers which can cause conflict with other code using Windows SDK. (#157)

Signed-off-by: Marat Abrarov <abrarov@gmail.com>
This commit is contained in:
Marat Abrarov
2024-04-16 11:47:28 +03:00
committed by GitHub
parent d1b7a61353
commit 39afcefb64

View File

@@ -18,7 +18,17 @@
#include <boost/core/noncopyable.hpp>
#include <boost/stacktrace/detail/to_dec_array.hpp>
#include <boost/stacktrace/detail/to_hex_array.hpp>
#ifdef WIN32_LEAN_AND_MEAN
#include <windows.h>
#else
// Prevent inclusion of extra Windows SDK headers which can cause conflict
// with other code using Windows SDK
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#undef WIN32_LEAN_AND_MEAN
#endif
#include "dbgeng.h"
#include <mutex>