X-Git-Url: http://git.tdb.fi/?p=libs%2Fgl.git;a=blobdiff_plain;f=source%2Fglsl%2Foptimize.cpp;fp=source%2Fglsl%2Foptimize.cpp;h=b7a722f42c96c6cc718de3b964697ac9416822bb;hp=d57002552540c6c375cb7446f8465a9538a0a42d;hb=d4b8a3f67c1f7184124bf95caee7e36ae8d6c82a;hpb=fb5f83c2e3f8f8a6a6444a33bec15e9477a487d1 diff --git a/source/glsl/optimize.cpp b/source/glsl/optimize.cpp index d5700255..b7a722f4 100644 --- a/source/glsl/optimize.cpp +++ b/source/glsl/optimize.cpp @@ -102,8 +102,7 @@ const string &InlineContentInjector::apply(Stage &stage, FunctionDeclaration &ta SetForScope set_pass(pass, RENAME); var->visit(*this); - staging_block.body.push_back(0); - staging_block.body.back() = var; + staging_block.body.push_back_nocopy(var); params.push_back(var); } @@ -117,8 +116,7 @@ const string &InlineContentInjector::apply(Stage &stage, FunctionDeclaration &ta SetForScope set_pass(pass, RENAME); r_inlined_statement->visit(*this); - staging_block.body.push_back(0); - staging_block.body.back() = r_inlined_statement; + staging_block.body.push_back_nocopy(r_inlined_statement); } /* Now collect names from the staging block. Local variables that would