]> git.tdb.fi Git - libs/gl.git/commitdiff
Output the interface block as is in the AST dump
authorMikko Rasa <tdb@tdb.fi>
Mon, 5 Apr 2021 11:13:36 +0000 (14:13 +0300)
committerMikko Rasa <tdb@tdb.fi>
Mon, 5 Apr 2021 11:13:36 +0000 (14:13 +0300)
This is more useful for debugging

source/glsl/debug.cpp

index 9336db618ac2a75dd9f5ed1f3077eff31a548f1e..8bdce457f0d1c318d56dd193c57309f30bdd0646 100644 (file)
@@ -17,15 +17,8 @@ const std::string &DumpTree::apply(Stage &stage)
        for(std::map<string, TypeDeclaration *>::const_iterator i=stage.types.begin(); i!=stage.types.end(); ++i)
                append(format("Type: %%%d %s", get_label(*i->second), i->first));
 
-       set<InterfaceBlock *> seen_interfaces;
        for(std::map<string, InterfaceBlock *>::const_iterator i=stage.interface_blocks.begin(); i!=stage.interface_blocks.end(); ++i)
-               if(seen_interfaces.insert(i->second).second)
-               {
-                       string text = format("Interface block: %%%d %s %s", get_label(*i->second), i->second->interface, i->second->block_name);
-                       if(!i->second->instance_name.empty())
-                               text += format(" %s", i->second->instance_name);
-                       append(text);
-               }
+               append(format("Interface block: %%%d %s", get_label(*i->second), i->first));
 
        for(std::map<string, FunctionDeclaration *>::const_iterator i=stage.functions.begin(); i!=stage.functions.end(); ++i)
                append(format("Function: %%%d %s", get_label(*i->second), i->first));