Call glsl_type::get_instance correctly: the number of rows must be at least 1
This causes the following tests to pass:
shaders/glsl-tex-mvp.vert
diff --git a/ir_variable.cpp b/ir_variable.cpp
index 29f3fc5..41359b5 100644
--- a/ir_variable.cpp
+++ b/ir_variable.cpp
@@ -120,7 +120,7 @@
* FINISHME: at least 2, so hard-code 2 for now.
*/
const glsl_type *const vec4_type =
- glsl_type::get_instance(GLSL_TYPE_FLOAT, 4, 0);
+ glsl_type::get_instance(GLSL_TYPE_FLOAT, 4, 1);
const glsl_type *const vec4_array_type =
glsl_type::get_array_instance(vec4_type, 2);
@@ -204,7 +204,7 @@
* FINISHME: at least 2, so hard-code 2 for now.
*/
const glsl_type *const vec4_type =
- glsl_type::get_instance(GLSL_TYPE_FLOAT, 4, 0);
+ glsl_type::get_instance(GLSL_TYPE_FLOAT, 4, 1);
const glsl_type *const vec4_array_type =
glsl_type::get_array_instance(vec4_type, 2);