Eventually they will be split or otherwise transformed before getting here.
Signed-off-by: Matteo Bruni mbruni@codeweavers.com --- v2: Report a compiler error (and fail compilation).
libs/vkd3d-shader/hlsl_sm1.c | 6 ++++++ libs/vkd3d-shader/vkd3d_shader_private.h | 1 + 2 files changed, 7 insertions(+)
diff --git a/libs/vkd3d-shader/hlsl_sm1.c b/libs/vkd3d-shader/hlsl_sm1.c index 8ea663dc..c13f0a2e 100644 --- a/libs/vkd3d-shader/hlsl_sm1.c +++ b/libs/vkd3d-shader/hlsl_sm1.c @@ -768,6 +768,12 @@ static void write_sm1_instructions(struct hlsl_ctx *ctx, struct vkd3d_bytecode_b FIXME("Matrix operations need to be lowered.\n"); break; } + if (instr->data_type->type == HLSL_CLASS_ARRAY) + { + hlsl_error(ctx, instr->loc, VKD3D_SHADER_ERROR_HLSL_COMPILER_ERROR, + "Compiler error, array operations need to be lowered."); + break; + }
assert(instr->data_type->type == HLSL_CLASS_SCALAR || instr->data_type->type == HLSL_CLASS_VECTOR); } diff --git a/libs/vkd3d-shader/vkd3d_shader_private.h b/libs/vkd3d-shader/vkd3d_shader_private.h index b64c4b10..4ea6f88d 100644 --- a/libs/vkd3d-shader/vkd3d_shader_private.h +++ b/libs/vkd3d-shader/vkd3d_shader_private.h @@ -112,6 +112,7 @@ enum vkd3d_shader_error VKD3D_SHADER_ERROR_HLSL_INVALID_RETURN = 5014, VKD3D_SHADER_ERROR_HLSL_OVERLAPPING_RESERVATIONS = 5015, VKD3D_SHADER_ERROR_HLSL_INVALID_RESERVATION = 5016, + VKD3D_SHADER_ERROR_HLSL_COMPILER_ERROR = 5299,
VKD3D_SHADER_WARNING_HLSL_IMPLICIT_TRUNCATION = 5300, };