From 8bf70f4d445cf63386ad7aafc5b3ebdbd8369939 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Thu, 22 Apr 2021 13:50:11 +0300 Subject: [PATCH] Fix the return value of ConstantFolder::apply This was causing the folded literals to be left without a type in some specific situations, since a resolve pass did not get run. --- source/glsl/optimize.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/source/glsl/optimize.cpp b/source/glsl/optimize.cpp index b1201e9f..ed20bb17 100644 --- a/source/glsl/optimize.cpp +++ b/source/glsl/optimize.cpp @@ -657,6 +657,7 @@ void ConstantFolder::visit(RefPtr &expr) } literal->value = r_constant_value; expr = literal; + r_any_folded = true; } void ConstantFolder::visit(Literal &literal) -- 2.45.2