glsl: Fix flipped return of has_value() for array constants.
authorEric Anholt <eric@anholt.net>
Thu, 2 Dec 2010 16:52:58 +0000 (08:52 -0800)
committerEric Anholt <eric@anholt.net>
Thu, 2 Dec 2010 18:28:51 +0000 (10:28 -0800)
Fixes glsl-array-uniform.

src/glsl/ir.cpp

index 31b90bf021c8445103e721e3376434589f697538..b8b0fed9d1cc760da6081add81b81810bc776702 100644 (file)
@@ -778,7 +778,7 @@ ir_constant::has_value(const ir_constant *c) const
 
    if (this->type->is_array()) {
       for (unsigned i = 0; i < this->type->length; i++) {
-        if (this->array_elements[i]->has_value(c->array_elements[i]))
+        if (!this->array_elements[i]->has_value(c->array_elements[i]))
            return false;
       }
       return true;