}
else
{
- readExtensionsExtensionRequireSkipped( child );
+ readExtensionsExtensionRequireRemove( child );
}
}
}
}
else
{
- checkForError( m_skippedFeatures.find( attribute.second ) != m_skippedFeatures.end(), line, "unknown feature <" + attribute.second + ">" );
- readExtensionsExtensionRequireSkipped( element );
+ checkForError( m_removedFeatures.find( attribute.second ) != m_removedFeatures.end(), line, "unknown feature <" + attribute.second + ">" );
+ readExtensionsExtensionRequireRemove( element );
return;
}
}
requireData.commands.push_back( name );
}
-void VulkanHppGenerator::readExtensionsExtensionRequireSkipped( tinyxml2::XMLElement const * element )
+void VulkanHppGenerator::readExtensionsExtensionRequireRemove( tinyxml2::XMLElement const * element )
{
int line = element->GetLineNum();
std::map<std::string, std::string> attributes = getAttributes( element );
std::string value = child->Value();
if ( value == "command" )
{
- readRequireCommandSkipped( child );
+ readRequireCommandRemove( child );
}
else if ( value == "type" )
{
- readRequireTypeSkipped( child );
+ readRequireTypeRemove( child );
}
}
}
{
checkForError( name == "VK_VERSION_" + modifiedNumber, line, "unexpected formatting of name <" + name + ">" );
checkForError( m_features.find( name ) == m_features.end(), line, "already specified feature <" + name + ">" );
- assert( m_skippedFeatures.find( name ) == m_skippedFeatures.end() );
+ assert( m_removedFeatures.find( name ) == m_removedFeatures.end() );
auto featureIt = m_features.insert( std::make_pair( name, number ) ).first;
for ( auto child : children )
{
// skip this feature
checkForError( name == "VKSC_VERSION_" + modifiedNumber, line, "unexpected formatting of name <" + name + ">" );
- checkForError( m_skippedFeatures.insert( name ).second, line, "already specified skipped feature <" + name + ">" );
+ checkForError( m_removedFeatures.insert( name ).second, line, "already specified skipped feature <" + name + ">" );
assert( m_features.find( name ) == m_features.end() );
for ( auto child : children )
std::string value = child->Value();
if ( value == "require" )
{
- readFeatureRequireSkipped( child );
+ readFeatureRequireRemove( child );
}
}
}
}
}
-void VulkanHppGenerator::readFeatureRequireCommandSkipped( tinyxml2::XMLElement const * element )
+void VulkanHppGenerator::readFeatureRequireCommandRemove( tinyxml2::XMLElement const * element )
{
int line = element->GetLineNum();
std::map<std::string, std::string> attributes = getAttributes( element );
requireData.commands.push_back( name );
}
-void VulkanHppGenerator::readFeatureRequireSkipped( tinyxml2::XMLElement const * element )
+void VulkanHppGenerator::readFeatureRequireRemove( tinyxml2::XMLElement const * element )
{
int line = element->GetLineNum();
checkAttributes( line, getAttributes( element ), {}, { { "comment", {} } } );
std::string value = child->Value();
if ( value == "command" )
{
- readFeatureRequireCommandSkipped( child );
+ readFeatureRequireCommandRemove( child );
}
else if ( value == "enum" )
{
- readRequireEnumSkipped( child );
+ readRequireEnumRemove( child );
}
else if ( value == "type" )
{
- readRequireTypeSkipped( child );
+ readRequireTypeRemove( child );
}
}
}
}
}
-void VulkanHppGenerator::readRequireCommandSkipped( tinyxml2::XMLElement const * element )
+void VulkanHppGenerator::readRequireCommandRemove( tinyxml2::XMLElement const * element )
{
int line = element->GetLineNum();
std::map<std::string, std::string> attributes = getAttributes( element );
auto commandIt = m_commands.find( name );
if ( commandIt != m_commands.end() )
{
- checkForError( m_skippedCommands.insert( name ).second, line, "to be skipped command <" + name + "> is already marked as skipped" );
+ checkForError( m_removedCommands.insert( name ).second, line, "to be skipped command <" + name + "> is already marked as skipped" );
m_commands.erase( commandIt );
}
else
{
- checkForError( m_skippedCommands.find( name ) != m_skippedCommands.end(),
+ checkForError( m_removedCommands.find( name ) != m_removedCommands.end(),
line,
"to be skipped command <" + name + "> is neither listed as command nor as skipped command" );
}
if ( enumIt == m_enums.end() )
{
// need to re-add a previously removed enum !!
- enumIt = m_skippedEnums.find( extends );
- checkForError( enumIt != m_skippedEnums.end(), line, "feature extends unknown enum <" + extends + ">" );
+ enumIt = m_removedEnums.find( extends );
+ checkForError( enumIt != m_removedEnums.end(), line, "feature extends unknown enum <" + extends + ">" );
enumIt = m_enums.insert( *enumIt ).first;
- auto typeIt = m_skippedTypes.find( extends );
- assert( ( m_types.find( extends ) == m_types.end() ) || ( typeIt != m_skippedTypes.end() ) );
+ auto typeIt = m_removedTypes.find( extends );
+ assert( ( m_types.find( extends ) == m_types.end() ) || ( typeIt != m_removedTypes.end() ) );
typeIt->second.referencedIn = extensionName;
m_types[extends] = typeIt->second;
- m_skippedTypes.erase( typeIt );
+ m_removedTypes.erase( typeIt );
}
// add this enum name to the list of values
}
}
-void VulkanHppGenerator::readRequireEnumSkipped( tinyxml2::XMLElement const * element )
+void VulkanHppGenerator::readRequireEnumRemove( tinyxml2::XMLElement const * element )
{
int line = element->GetLineNum();
std::map<std::string, std::string> attributes = getAttributes( element );
}
}
-void VulkanHppGenerator::readRequireTypeSkipped( tinyxml2::XMLElement const * element )
+void VulkanHppGenerator::readRequireTypeRemove( tinyxml2::XMLElement const * element )
{
int line = element->GetLineNum();
std::map<std::string, std::string> attributes = getAttributes( element );
if ( typeIt != m_types.end() )
{
assert( typeIt->second.referencedIn.empty() );
- assert( m_skippedTypes.find( name ) == m_skippedTypes.end() );
+ assert( m_removedTypes.find( name ) == m_removedTypes.end() );
switch ( typeIt->second.category )
{
{
auto enumIt = m_enums.find( name );
assert( enumIt != m_enums.end() );
- assert( m_skippedEnums.find( name ) == m_skippedEnums.end() );
- m_skippedEnums[name] = enumIt->second;
+ assert( m_removedEnums.find( name ) == m_removedEnums.end() );
+ m_removedEnums[name] = enumIt->second;
m_enums.erase( enumIt );
}
break;
default: assert( false ); break;
}
- m_skippedTypes[name] = typeIt->second;
+ m_removedTypes[name] = typeIt->second;
m_types.erase( typeIt );
}
}
int xmlLine;
};
- struct SkippedExtensionData
- {
- SkippedExtensionData( int line, std::string const & platform_ ) : platform( platform_ ), xmlLine( line ) {}
-
- std::string platform;
- int xmlLine;
- };
-
struct ComponentData
{
ComponentData( int line ) : xmlLine( line ) {}
void readExtensionsExtension( tinyxml2::XMLElement const * element );
void readExtensionsExtensionRequire( tinyxml2::XMLElement const * element, std::map<std::string, ExtensionData>::iterator extensionIt );
void readExtensionsExtensionRequireCommand( tinyxml2::XMLElement const * element, std::string const & extensionName, RequireData & requireData );
- void readExtensionsExtensionRequireSkipped( tinyxml2::XMLElement const * element );
+ void readExtensionsExtensionRequireRemove( tinyxml2::XMLElement const * element );
void readExtensionsExtensionRequireType( tinyxml2::XMLElement const * element, std::string const & extensionName, RequireData & requireData );
void readFeature( tinyxml2::XMLElement const * element );
void readFeatureRequire( tinyxml2::XMLElement const * element, std::map<std::string, FeatureData>::iterator featureIt );
void readFeatureRequireCommand( tinyxml2::XMLElement const * element, std::map<std::string, FeatureData>::iterator featureIt, RequireData & requireData );
- void readFeatureRequireCommandSkipped( tinyxml2::XMLElement const * element );
- void readFeatureRequireSkipped( tinyxml2::XMLElement const * element );
+ void readFeatureRequireCommandRemove( tinyxml2::XMLElement const * element );
+ void readFeatureRequireRemove( tinyxml2::XMLElement const * element );
void readFeatureRequireType( tinyxml2::XMLElement const * element, std::map<std::string, FeatureData>::iterator featureIt, RequireData & requireData );
void readFormats( tinyxml2::XMLElement const * element );
void readFormatsFormat( tinyxml2::XMLElement const * element );
void readPlatforms( tinyxml2::XMLElement const * element );
void readPlatformsPlatform( tinyxml2::XMLElement const * element );
void readRegistry( tinyxml2::XMLElement const * element );
- void readRequireCommandSkipped( tinyxml2::XMLElement const * element );
+ void readRequireCommandRemove( tinyxml2::XMLElement const * element );
void readRequireEnum( tinyxml2::XMLElement const * element, std::string const & extensionName );
- void readRequireEnumSkipped( tinyxml2::XMLElement const * element );
- void readRequireTypeSkipped( tinyxml2::XMLElement const * element );
+ void readRequireEnumRemove( tinyxml2::XMLElement const * element );
+ void readRequireTypeRemove( tinyxml2::XMLElement const * element );
void readSPIRVCapabilities( tinyxml2::XMLElement const * element );
void readSPIRVCapabilitiesSPIRVCapability( tinyxml2::XMLElement const * element );
void readSPIRVCapabilitiesSPIRVCapabilityEnable( tinyxml2::XMLElement const * element );
std::set<std::string> m_includes;
std::map<std::string, PlatformData> m_platforms;
std::set<std::string> m_RAIISpecialFunctions;
- std::map<std::string, EnumData> m_skippedEnums;
- std::set<std::string> m_skippedCommands;
- std::set<std::string> m_skippedFeatures;
- std::map<std::string, TypeData> m_skippedTypes;
+ std::set<std::string> m_removedCommands;
+ std::map<std::string, EnumData> m_removedEnums;
+ std::set<std::string> m_removedFeatures;
+ std::map<std::string, TypeData> m_removedTypes;
std::map<std::string, StructureData> m_structures;
std::map<std::string, StructureAliasData> m_structureAliases;
std::map<std::string, std::set<std::string>> m_structureAliasesInverse;