From: Mikko Rasa Date: Wed, 3 Mar 2021 10:41:15 +0000 (+0200) Subject: Fix a block management error in FunctionInliner X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=223e295e4404a3913b8243d3b7eb12da39a68144;p=libs%2Fgl.git Fix a block management error in FunctionInliner --- diff --git a/source/glsl/optimize.cpp b/source/glsl/optimize.cpp index 8d3eca9e..08455c8a 100644 --- a/source/glsl/optimize.cpp +++ b/source/glsl/optimize.cpp @@ -199,6 +199,7 @@ void FunctionInliner::visit_and_inline(RefPtr &ptr) void FunctionInliner::visit(Block &block) { + SetForScope set_block(current_block, &block); SetForScope::iterator> save_insert_point(insert_point, block.body.begin()); for(NodeList::iterator i=block.body.begin(); i!=block.body.end(); ++i) {