glsl: allow out arrays in #110 with allow_glsl_120_subset_in_110

CC: mesa-stable
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28439>
(cherry picked from commit bd189dbd77)
This commit is contained in:
Paul Gofman 2024-03-27 16:39:03 -06:00 committed by Eric Engestrom
parent dac8689fc3
commit 50669655ed
2 changed files with 2 additions and 2 deletions

View file

@ -484,7 +484,7 @@
"description": "glsl: allow out arrays in #110 with allow_glsl_120_subset_in_110",
"nominated": true,
"nomination_type": 0,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": null,
"notes": null

View file

@ -6058,7 +6058,7 @@ ast_parameter_declarator::hir(exec_list *instructions,
*/
if ((var->data.mode == ir_var_function_inout || var->data.mode == ir_var_function_out)
&& glsl_type_is_array(type)
&& !state->check_version(120, 100, &loc,
&& !state->check_version(state->allow_glsl_120_subset_in_110 ? 110 : 120, 100, &loc,
"arrays cannot be out or inout parameters")) {
type = &glsl_type_builtin_error;
}