d3dcompiler: Check for multiple matrix majority keywords on typedefs.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2020-04-02 16:14:10 -05:00 committed by Alexandre Julliard
parent 5e75310837
commit d05ee3674e
1 changed files with 4 additions and 0 deletions

View File

@ -814,6 +814,10 @@ static BOOL add_typedef(DWORD modifiers, struct hlsl_type *orig_type, struct lis
if (type->type != HLSL_CLASS_MATRIX)
check_invalid_matrix_modifiers(type->modifiers, v->loc);
if ((type->modifiers & HLSL_MODIFIER_COLUMN_MAJOR)
&& (type->modifiers & HLSL_MODIFIER_ROW_MAJOR))
hlsl_report_message(v->loc, HLSL_LEVEL_ERROR, "more than one matrix majority keyword");
ret = add_type_to_scope(hlsl_ctx.cur_scope, type);
if (!ret)
{