From 7318a091be3b0b844b05699f05715f0ec558162f Mon Sep 17 00:00:00 2001 From: asuessenbach Date: Wed, 3 Mar 2021 08:47:05 +0100 Subject: [PATCH] Make attribute provisional="true" imply attribute platform="provisional" --- VulkanHppGenerator.cpp | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/VulkanHppGenerator.cpp b/VulkanHppGenerator.cpp index 33ac01f..a796f4e 100644 --- a/VulkanHppGenerator.cpp +++ b/VulkanHppGenerator.cpp @@ -11859,14 +11859,19 @@ void VulkanHppGenerator::readExtension( tinyxml2::XMLElement const * element ) { promotedTo = attribute.second; } -#if !defined( NDEBUG ) else if ( attribute.first == "provisional" ) { - check( platform == "provisional", - line, - "while attribute is set to \"true\", attribute is not set to \"provisional\"" ); + if ( platform.empty() ) + { + // for now, having the attribute provisional="true" implies attribute platform="provisional" to get stuff protected by VK_ENABLE_BETA_EXTENSIONS + platform = "provisional"; + } + check( + platform == "provisional", + line, + "while attribute is set to \"true\", attribute is not set to \"provisional\" but to \"" + + platform + "\"" ); } -#endif else if ( attribute.first == "requires" ) { requirements = tokenize( attribute.second, "," );