From 69ec384bbaddc225404943607e12c2be6fe0199f Mon Sep 17 00:00:00 2001 From: Boris Brezillon Date: Mon, 22 Nov 2021 05:41:35 -0800 Subject: [PATCH] gallium/d3d12: Don't use designated initializers Use of designated initializers requires at least '/std:c++20', and mesa is using c++14 by default. Fixes: 8d3a3e7a00b ("microsoft/compiler: Use textures for SRVs") Signed-off-by: Boris Brezillon Reviewed-by: Jesse Natalie Part-of: --- src/gallium/drivers/d3d12/d3d12_compiler.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/d3d12/d3d12_compiler.cpp b/src/gallium/drivers/d3d12/d3d12_compiler.cpp index 35f253ac07d..eb528a0fdf4 100644 --- a/src/gallium/drivers/d3d12/d3d12_compiler.cpp +++ b/src/gallium/drivers/d3d12/d3d12_compiler.cpp @@ -145,7 +145,8 @@ compile_nir(struct d3d12_context *ctx, struct d3d12_shader_selector *sel, NIR_PASS_V(nir, dxil_nir_split_typed_samplers); NIR_PASS_V(nir, nir_opt_dce); - struct nir_remove_dead_variables_options dead_var_opts = { .can_remove_var = can_remove_dead_sampler }; + struct nir_remove_dead_variables_options dead_var_opts = {}; + dead_var_opts.can_remove_var = can_remove_dead_sampler; NIR_PASS_V(nir, nir_remove_dead_variables, nir_var_uniform, &dead_var_opts); if (key->samples_int_textures)