mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-09-13 09:16:14 -07:00
include: Add min() & max() macros.
This commit is contained in:
parent
2976d7798d
commit
821d978950
@ -179,6 +179,7 @@ typedef struct SECURITY_ATTRIBUTES SECURITY_ATTRIBUTES;
|
||||
#endif /* _WIN32 */
|
||||
|
||||
|
||||
/* Nameless unions */
|
||||
#ifndef __C89_NAMELESS
|
||||
# ifdef NONAMELESSUNION
|
||||
# define __C89_NAMELESS
|
||||
@ -189,4 +190,13 @@ typedef struct SECURITY_ATTRIBUTES SECURITY_ATTRIBUTES;
|
||||
# endif /* NONAMELESSUNION */
|
||||
#endif /* __C89_NAMELESS */
|
||||
|
||||
/* Define min() & max() macros */
|
||||
#ifndef min
|
||||
# define min(a, b) (((a) <= (b)) ? (a) : (b))
|
||||
#endif
|
||||
|
||||
#ifndef max
|
||||
# define max(a, b) (((a) >= (b)) ? (a) : (b))
|
||||
#endif
|
||||
|
||||
#endif /* __VKD3D_WINDOWS_H */
|
||||
|
Loading…
Reference in New Issue
Block a user