mirror of
https://github.com/KhronosGroup/Vulkan-Hpp.git
synced 2024-10-14 16:32:17 +00:00
Filter (implicitly) required "FlagBits"-enums that are explicitly listed later on in an extension.
This commit is contained in:
parent
4d15474961
commit
7316e08630
@ -2695,7 +2695,9 @@ void VulkanHppGenerator::appendEnums( std::string & str ) const
|
|||||||
for ( auto const & type : extIt.second->second.types )
|
for ( auto const & type : extIt.second->second.types )
|
||||||
{
|
{
|
||||||
auto enumIt = m_enums.find( type );
|
auto enumIt = m_enums.find( type );
|
||||||
if ( enumIt != m_enums.end() )
|
// some "FlagBits"-enums are implicitly added to a feature, as the corresponding "Flags"-enum needs it !!
|
||||||
|
// => it can happen that a "FlagBits"-enum explicitly listed for an extension is already listed with a feature!
|
||||||
|
if ( enumIt != m_enums.end() && listedEnums.insert( type ).second )
|
||||||
{
|
{
|
||||||
enumIts.push_back( enumIt );
|
enumIts.push_back( enumIt );
|
||||||
}
|
}
|
||||||
@ -2712,9 +2714,6 @@ void VulkanHppGenerator::appendEnums( std::string & str ) const
|
|||||||
str += enter + "\n //=== " + extIt.second->first + " ===\n";
|
str += enter + "\n //=== " + extIt.second->first + " ===\n";
|
||||||
for ( auto enumIt : enumIts )
|
for ( auto enumIt : enumIts )
|
||||||
{
|
{
|
||||||
assert( listedEnums.find( enumIt->first ) == listedEnums.end() );
|
|
||||||
listedEnums.insert( enumIt->first );
|
|
||||||
|
|
||||||
str += "\n";
|
str += "\n";
|
||||||
appendEnum( str, *enumIt );
|
appendEnum( str, *enumIt );
|
||||||
appendEnumToString( str, *enumIt );
|
appendEnumToString( str, *enumIt );
|
||||||
|
Loading…
Reference in New Issue
Block a user