From b345f7615a657c73af2272c5fb7cefa9a8f5b7ef Mon Sep 17 00:00:00 2001 From: lizzie Date: Thu, 10 Sep 2026 03:19:32 +0000 Subject: [PATCH] 2026-09-10 03:19:32 Signed-off-by: lizzie --- .../backend/glsl/emit_glsl.cpp | 22 +++---------------- 1 file changed, 3 insertions(+), 19 deletions(-) diff --git a/src/shader_recompiler/backend/glsl/emit_glsl.cpp b/src/shader_recompiler/backend/glsl/emit_glsl.cpp index 66ecfc9f74..8735a5e90c 100644 --- a/src/shader_recompiler/backend/glsl/emit_glsl.cpp +++ b/src/shader_recompiler/backend/glsl/emit_glsl.cpp @@ -28,11 +28,6 @@ struct FuncTraits { using ArgType = std::tuple_element_t>; }; -template -void SetDefinition(EmitContext& ctx, IR::Inst* inst, Args... args) { - inst->SetDefinition(func(ctx, std::forward(args)...)); -} - template auto Arg(EmitContext& ctx, const IR::Value& arg) { if constexpr (std::is_same_v) { @@ -53,21 +48,10 @@ auto Arg(EmitContext& ctx, const IR::Value& arg) { template void Invoke(EmitContext& ctx, IR::Inst* inst, std::index_sequence) { using Traits = FuncTraits; - if constexpr (std::is_same_v) { - if constexpr (is_first_arg_inst) { - SetDefinition( - ctx, inst, *inst, - Arg>(ctx, inst->Arg(I))...); - } else { - SetDefinition( - ctx, inst, Arg>(ctx, inst->Arg(I))...); - } + if constexpr (is_first_arg_inst) { + func(ctx, *inst, Arg>(ctx, inst->Arg(I))...); } else { - if constexpr (is_first_arg_inst) { - func(ctx, *inst, Arg>(ctx, inst->Arg(I))...); - } else { - func(ctx, Arg>(ctx, inst->Arg(I))...); - } + func(ctx, Arg>(ctx, inst->Arg(I))...); } }