Matteo Bruni : vkd3d-compiler: Set default source type before handling --print-target-types.

Alexandre Julliard julliard at winehq.org
Fri Jan 29 14:54:48 CST 2021


Module: vkd3d
Branch: master
Commit: 5399f6fcc6cbf77a25b860eee9e500539df4fab6
URL:    https://source.winehq.org/git/vkd3d.git/?a=commit;h=5399f6fcc6cbf77a25b860eee9e500539df4fab6

Author: Matteo Bruni <mbruni at codeweavers.com>
Date:   Thu Jan 28 18:43:43 2021 +0100

vkd3d-compiler: Set default source type before handling --print-target-types.

Signed-off-by: Matteo Bruni <mbruni at codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 programs/vkd3d-compiler/main.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/programs/vkd3d-compiler/main.c b/programs/vkd3d-compiler/main.c
index 94cce20..e98e713 100644
--- a/programs/vkd3d-compiler/main.c
+++ b/programs/vkd3d-compiler/main.c
@@ -480,14 +480,14 @@ static bool parse_command_line(int argc, char **argv, struct options *options)
         }
     }
 
-    if (options->print_target_types)
-        return true;
-
     if (options->source_type == VKD3D_SHADER_SOURCE_NONE)
         options->source_type = options->preprocess_only ? VKD3D_SHADER_SOURCE_HLSL : VKD3D_SHADER_SOURCE_DXBC_TPF;
     if (options->target_type == VKD3D_SHADER_TARGET_NONE && !options->preprocess_only)
         options->target_type = VKD3D_SHADER_TARGET_SPIRV_BINARY;
 
+    if (options->print_target_types)
+        return true;
+
     if (!options->preprocess_only && !validate_target_type(options->source_type, options->target_type))
     {
         fprintf(stderr, "Target type '%s' is invalid for source type '%s'.\n",




More information about the wine-cvs mailing list