glsl: Use the without_array predicate
authorTimothy Arceri <t_arceri@yahoo.com.au>
Thu, 19 Feb 2015 10:32:21 +0000 (21:32 +1100)
committerTimothy Arceri <t_arceri@yahoo.com.au>
Fri, 20 Feb 2015 05:11:15 +0000 (16:11 +1100)
Reviewed-by: Matt Turner <mattst88@gmail.com>
src/glsl/ir.h

index ce35b2bf2134fd0e74da3fd616df3f960bd2d1bc..25f2ecada0f677a342712fa16a18938cad690d1e 100644 (file)
@@ -450,11 +450,8 @@ public:
     */
    inline bool is_interface_instance() const
    {
-      const glsl_type *const t = this->type;
-
-      return (t == this->interface_type)
-         || (t->is_array() && t->fields.array == this->interface_type);
-    }
+      return this->type->without_array() == this->interface_type;
+   }
 
    /**
     * Set this->interface_type on a newly created variable.