From 58a9601dffa6d9b3b881a476169458787d382919 Mon Sep 17 00:00:00 2001 From: fanquake Date: Mon, 20 Jun 2022 11:43:21 +0100 Subject: build: globally define NOMINMAX Define (and document) `NOMINMAX` once, rather than across multiple source files. Defining this prevents the definition of min/max macros when using mingw-w64, which may conflict with unprefixed std::min/max usage. While that might not be the case for us, we'd always prefer to use the standard library in any case. For example: https://github.com/mingw-w64/mingw-w64/blob/73cadc06c62c6af5faf76f64ef08e684b48de48c/mingw-w64-headers/include/ntdef.h#L289-L300 --- src/support/lockedpool.cpp | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/support') diff --git a/src/support/lockedpool.cpp b/src/support/lockedpool.cpp index b7ef479675..e48accf0a4 100644 --- a/src/support/lockedpool.cpp +++ b/src/support/lockedpool.cpp @@ -10,9 +10,6 @@ #endif #ifdef WIN32 -#ifndef NOMINMAX -#define NOMINMAX -#endif #include #else #include // for mmap -- cgit v1.2.3