From bdbeec5191035a04aeb513c883876f5223aefce4 Mon Sep 17 00:00:00 2001 From: lwxxxxxxx <1433359185@qq.com> Date: Thu, 23 Jan 2025 23:54:34 +0800 Subject: [PATCH] fix a bug for C++20 --- src/libspu/mpc/swift/arithmetic.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/libspu/mpc/swift/arithmetic.cc b/src/libspu/mpc/swift/arithmetic.cc index c0e89184..5cb484a4 100644 --- a/src/libspu/mpc/swift/arithmetic.cc +++ b/src/libspu/mpc/swift/arithmetic.cc @@ -1841,7 +1841,11 @@ NdArrayRef TruncA::proc(KernelEvalContext* ctx, const NdArrayRef& x, auto numel = x.numel(); auto a2p = A2P(); - auto [r, rd] = TruncA::Trgen(ctx, static_cast(bits), field, numel); + auto trunc_pair = + TruncA::Trgen(ctx, static_cast(bits), field, numel); + + auto r = trunc_pair.first; + auto rd = trunc_pair.second; r.reshape(x.shape()); rd.reshape(x.shape());