From: Antia Puentes Date: Thu, 15 Nov 2018 08:13:08 +0000 (+0100) Subject: nir/types: Add glsl_type_is_unsized_array helper X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=cafc1a40d465a42805bb2ae45b18997e87bbac75;p=mesa.git nir/types: Add glsl_type_is_unsized_array helper Reviewed-by: Caio Marcelo de Oliveira Filho --- diff --git a/src/compiler/nir_types.cpp b/src/compiler/nir_types.cpp index 3b6362e66fa..15c752676f4 100644 --- a/src/compiler/nir_types.cpp +++ b/src/compiler/nir_types.cpp @@ -279,6 +279,12 @@ glsl_type_is_array(const struct glsl_type *type) return type->is_array(); } +bool +glsl_type_is_unsized_array(const struct glsl_type *type) +{ + return type->is_unsized_array(); +} + bool glsl_type_is_array_of_arrays(const struct glsl_type *type) { diff --git a/src/compiler/nir_types.h b/src/compiler/nir_types.h index 9efe4b4770c..7b2512792b8 100644 --- a/src/compiler/nir_types.h +++ b/src/compiler/nir_types.h @@ -121,6 +121,7 @@ bool glsl_type_is_vector_or_scalar(const struct glsl_type *type); bool glsl_type_is_matrix(const struct glsl_type *type); bool glsl_matrix_type_is_row_major(const struct glsl_type *type); bool glsl_type_is_array(const struct glsl_type *type); +bool glsl_type_is_unsized_array(const struct glsl_type *type); bool glsl_type_is_array_of_arrays(const struct glsl_type *type); bool glsl_type_is_array_or_matrix(const struct glsl_type *type); bool glsl_type_is_struct(const struct glsl_type *type);