From 957ba91fa6c0b654d90ca3db04405bf9b11f8ae4 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 16 Feb 2026 08:21:41 +0000 Subject: [PATCH] Revert "Fix invalid zero representation in set_big_i64 and set_big_ui64" Co-authored-by: nunoplopes <2998477+nunoplopes@users.noreply.github.com> --- src/util/mpz.cpp | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/util/mpz.cpp b/src/util/mpz.cpp index 9b0949114..8445ec134 100644 --- a/src/util/mpz.cpp +++ b/src/util/mpz.cpp @@ -259,10 +259,6 @@ void mpz_manager::sub(mpz const & a, mpz const & b, mpz & c) { template void mpz_manager::set_big_i64(mpz & c, int64_t v) { - if (v == 0) { - set(c, 0); - return; - } uint64_t _v; bool sign = v < 0; if (v == std::numeric_limits::min()) { @@ -313,10 +309,6 @@ void mpz_manager::set_big_i64(mpz & c, int64_t v) { template void mpz_manager::set_big_ui64(mpz & c, uint64_t v) { - if (v == 0) { - set(c, 0); - return; - } #ifndef _MP_GMP if (c.is_small()) { c.set_ptr(allocate(m_init_cell_capacity), false, false); // positive, owned