summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/glsl/loop_analysis.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/glsl/loop_analysis.cpp b/src/glsl/loop_analysis.cpp
index c7f929590ab..9fc7672fb39 100644
--- a/src/glsl/loop_analysis.cpp
+++ b/src/glsl/loop_analysis.cpp
@@ -52,9 +52,10 @@ loop_variable::record_reference(bool in_assignee,
if (in_assignee) {
assert(current_assignment != NULL);
- this->conditional_or_nested_assignment =
- in_conditional_code_or_nested_loop
- || current_assignment->condition != NULL;
+ if (in_conditional_code_or_nested_loop ||
+ current_assignment->condition != NULL) {
+ this->conditional_or_nested_assignment = true;
+ }
if (this->first_assignment == NULL) {
assert(this->num_assignments == 0);