aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/glsl/hir_field_selection.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/glsl/hir_field_selection.cpp')
-rw-r--r--mesalib/src/glsl/hir_field_selection.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/mesalib/src/glsl/hir_field_selection.cpp b/mesalib/src/glsl/hir_field_selection.cpp
index 08be74365..1e92c89ae 100644
--- a/mesalib/src/glsl/hir_field_selection.cpp
+++ b/mesalib/src/glsl/hir_field_selection.cpp
@@ -72,7 +72,7 @@ _mesa_ast_field_selection_to_hir(const ast_expression *expr,
_mesa_glsl_error(&loc, state, "length method takes no arguments");
if (op->type->is_array()) {
- if (op->type->array_size() == 0)
+ if (op->type->is_unsized_array())
_mesa_glsl_error(&loc, state, "length called on unsized array");
result = new(ctx) ir_constant(op->type->array_size());