mirror of
https://github.com/KhronosGroup/Vulkan-Hpp.git
synced 2024-10-14 16:32:17 +00:00
Merge pull request #1060 from asuessenbach/alias
Downgrade attribute "extends" of enum alias elements from required to optional.
This commit is contained in:
commit
4c8d98c81a
@ -14010,7 +14010,7 @@ void VulkanHppGenerator::readRequireEnumAlias( tinyxml2::XMLElement const *
|
|||||||
std::map<std::string, std::string> const & attributes )
|
std::map<std::string, std::string> const & attributes )
|
||||||
{
|
{
|
||||||
int line = element->GetLineNum();
|
int line = element->GetLineNum();
|
||||||
checkAttributes( line, attributes, { { "alias", {} }, { "extends", {} }, { "name", {} } }, { { "comment", {} } } );
|
checkAttributes( line, attributes, { { "alias", {} }, { "name", {} } }, { { "comment", {} }, { "extends", {} } } );
|
||||||
checkElements( line, getChildElements( element ), {} );
|
checkElements( line, getChildElements( element ), {} );
|
||||||
|
|
||||||
std::string alias, bitpos, name, extends, extnumber, offset, value;
|
std::string alias, bitpos, name, extends, extnumber, offset, value;
|
||||||
@ -14030,11 +14030,14 @@ void VulkanHppGenerator::readRequireEnumAlias( tinyxml2::XMLElement const *
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
auto enumIt = m_enums.find( extends );
|
if ( !extends.empty() )
|
||||||
check( enumIt != m_enums.end(), line, "feature extends unknown enum <" + extends + ">" );
|
{
|
||||||
|
auto enumIt = m_enums.find( extends );
|
||||||
|
check( enumIt != m_enums.end(), line, "feature extends unknown enum <" + extends + ">" );
|
||||||
|
|
||||||
// add this enum name to the list of aliases
|
// add this enum name to the list of aliases
|
||||||
enumIt->second.addEnumAlias( line, name, alias );
|
enumIt->second.addEnumAlias( line, name, alias );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void VulkanHppGenerator::readRequires( tinyxml2::XMLElement const * element,
|
void VulkanHppGenerator::readRequires( tinyxml2::XMLElement const * element,
|
||||||
|
Loading…
Reference in New Issue
Block a user