mirror of
https://github.com/KhronosGroup/Vulkan-Hpp.git
synced 2024-10-14 16:32:17 +00:00
Don't fail on new platforms tag (#188)
This commit is contained in:
parent
ce87df93b5
commit
82a14093cf
@ -28,9 +28,9 @@ const std::string vkNamespace = R"(
|
|||||||
#define VULKAN_HPP_NAMESPACE vk
|
#define VULKAN_HPP_NAMESPACE vk
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define VULKAN_HPP_STRINGIFY2(text) #text
|
#define VULKAN_HPP_STRINGIFY2(text) #text
|
||||||
#define VULKAN_HPP_STRINGIFY(text) VULKAN_HPP_STRINGIFY2(text)
|
#define VULKAN_HPP_STRINGIFY(text) VULKAN_HPP_STRINGIFY2(text)
|
||||||
#define VULKAN_HPP_NAMESPACE_STRING VULKAN_HPP_STRINGIFY(VULKAN_HPP_NAMESPACE)
|
#define VULKAN_HPP_NAMESPACE_STRING VULKAN_HPP_STRINGIFY(VULKAN_HPP_NAMESPACE)
|
||||||
|
|
||||||
namespace VULKAN_HPP_NAMESPACE
|
namespace VULKAN_HPP_NAMESPACE
|
||||||
{
|
{
|
||||||
@ -4888,7 +4888,7 @@ int main( int argc, char **argv )
|
|||||||
assert(!registryElement->NextSiblingElement());
|
assert(!registryElement->NextSiblingElement());
|
||||||
|
|
||||||
std::vector<tinyxml2::XMLElement const*> children = getChildElements(registryElement);
|
std::vector<tinyxml2::XMLElement const*> children = getChildElements(registryElement);
|
||||||
checkElements(children, { "commands", "comment", "enums", "extensions", "feature", "tags", "types", "vendorids" });
|
checkElements(children, { "commands", "comment", "enums", "extensions", "feature", "tags", "types", "vendorids", "platforms" });
|
||||||
for (auto child : children)
|
for (auto child : children)
|
||||||
{
|
{
|
||||||
const std::string value = child->Value();
|
const std::string value = child->Value();
|
||||||
@ -4921,13 +4921,22 @@ int main( int argc, char **argv )
|
|||||||
{
|
{
|
||||||
generator.readTypes(child);
|
generator.readTypes(child);
|
||||||
}
|
}
|
||||||
else
|
else if (value == "vendorids")
|
||||||
{
|
{
|
||||||
assert(value == "vendorids");
|
|
||||||
#if !defined(NDEBUG)
|
#if !defined(NDEBUG)
|
||||||
generator.skipVendorIDs(child);
|
generator.skipVendorIDs(child);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
else if (value == "platforms")
|
||||||
|
{
|
||||||
|
// skip this tag
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
std::stringstream lineNumber;
|
||||||
|
lineNumber << child->GetLineNum();
|
||||||
|
throw std::runtime_error(std::string("unknown tag ") + value + " at line number:" + lineNumber.str());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
generator.sortDependencies();
|
generator.sortDependencies();
|
||||||
|
Loading…
Reference in New Issue
Block a user