Zebediah Figura : d3dcompiler: Check for multiple matrix majority keywords on typedefs.

Alexandre Julliard julliard at winehq.org
Tue Apr 14 16:15:25 CDT 2020


Module: wine
Branch: master
Commit: d05ee3674efc9227ab628ac71d8acc6e82aa2560
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=d05ee3674efc9227ab628ac71d8acc6e82aa2560

Author: Zebediah Figura <z.figura12 at gmail.com>
Date:   Thu Apr  2 16:14:10 2020 -0500

d3dcompiler: Check for multiple matrix majority keywords on typedefs.

Signed-off-by: Zebediah Figura <zfigura at codeweavers.com>
Signed-off-by: Matteo Bruni <mbruni at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/d3dcompiler_43/hlsl.y | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/dlls/d3dcompiler_43/hlsl.y b/dlls/d3dcompiler_43/hlsl.y
index 67393f6ca9..5381fa211a 100644
--- a/dlls/d3dcompiler_43/hlsl.y
+++ b/dlls/d3dcompiler_43/hlsl.y
@@ -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)
         {




More information about the wine-cvs mailing list