c++: Make some defines C++-valid

This commit is contained in:
Eidolon 2022-12-12 16:38:25 -06:00
parent dceeadd3aa
commit 15acefcc33

View file

@ -614,12 +614,14 @@ UINT32 quickncasehash (const char *p, size_t n)
return x; return x;
} }
#ifndef __cplusplus
#ifndef min // Double-Check with WATTCP-32's cdefs.h #ifndef min // Double-Check with WATTCP-32's cdefs.h
#define min(x, y) (((x) < (y)) ? (x) : (y)) #define min(x, y) (((x) < (y)) ? (x) : (y))
#endif #endif
#ifndef max // Double-Check with WATTCP-32's cdefs.h #ifndef max // Double-Check with WATTCP-32's cdefs.h
#define max(x, y) (((x) > (y)) ? (x) : (y)) #define max(x, y) (((x) > (y)) ? (x) : (y))
#endif #endif
#endif
// Max gamepad/joysticks that can be detected/used. // Max gamepad/joysticks that can be detected/used.
#define MAX_JOYSTICKS 4 #define MAX_JOYSTICKS 4