mirror of
https://github.com/KhronosGroup/Vulkan-Hpp.git
synced 2024-10-14 16:32:17 +00:00
Undef True/False in case they are defined and introduce some constexpr True/False to replace them. (#1610)
This commit is contained in:
parent
c115fd1ec6
commit
d748663707
@ -14,6 +14,17 @@
|
|||||||
# undef MemoryBarrier
|
# undef MemoryBarrier
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// XLib.h defines True/False, which collides with our vk::True/vk::False
|
||||||
|
// -> undef them and provide some namepace-secure constexpr
|
||||||
|
#if defined( True )
|
||||||
|
# undef True
|
||||||
|
constexpr int True = 1;
|
||||||
|
#endif
|
||||||
|
#if defined( False )
|
||||||
|
# undef False
|
||||||
|
constexpr int False = 0;
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(__GNUC__)
|
#if defined(__GNUC__)
|
||||||
# define GCC_VERSION ( __GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__ )
|
# define GCC_VERSION ( __GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__ )
|
||||||
#endif
|
#endif
|
||||||
|
@ -140,6 +140,17 @@ static_assert( VK_HEADER_VERSION == 256, "Wrong VK_HEADER_VERSION!" );
|
|||||||
# undef MemoryBarrier
|
# undef MemoryBarrier
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// XLib.h defines True/False, which collides with our vk::True/vk::False
|
||||||
|
// -> undef them and provide some namepace-secure constexpr
|
||||||
|
#if defined( True )
|
||||||
|
# undef True
|
||||||
|
constexpr int True = 1;
|
||||||
|
#endif
|
||||||
|
#if defined( False )
|
||||||
|
# undef False
|
||||||
|
constexpr int False = 0;
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined( __GNUC__ )
|
#if defined( __GNUC__ )
|
||||||
# define GCC_VERSION ( __GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__ )
|
# define GCC_VERSION ( __GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__ )
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user