vkd3d-shader/hlsl: Handle error expressions in array sizes.

This commit is contained in:
Elizabeth Figura 2024-08-29 12:48:23 -05:00 committed by Henri Verbeet
parent 8b98e483ac
commit 7905c47765
Notes: Henri Verbeet 2024-10-28 18:10:10 +01:00
Approved-by: Francisco Casas (@fcasas)
Approved-by: Henri Verbeet (@hverbeet)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1214

View File

@ -647,6 +647,9 @@ static struct hlsl_default_value evaluate_static_expression(struct hlsl_ctx *ctx
struct hlsl_block expr; struct hlsl_block expr;
struct hlsl_src src; struct hlsl_src src;
if (node_from_block(block)->data_type->class == HLSL_CLASS_ERROR)
return ret;
LIST_FOR_EACH_ENTRY(node, &block->instrs, struct hlsl_ir_node, entry) LIST_FOR_EACH_ENTRY(node, &block->instrs, struct hlsl_ir_node, entry)
{ {
switch (node->type) switch (node->type)