From 69003c80d4b6cb17a5d905400dc53aa5487afed5 Mon Sep 17 00:00:00 2001 From: Tom Godden <8372989+tgodden@users.noreply.github.com> Date: Fri, 20 Jan 2023 02:01:05 +0100 Subject: [PATCH] Fix for add_many (issue #23) (#113) Co-authored-by: Tom Godden Co-authored-by: mmagician Co-authored-by: Pratyush Mishra --- src/bits/uint.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bits/uint.rs b/src/bits/uint.rs index c2fa303..b575af4 100644 --- a/src/bits/uint.rs +++ b/src/bits/uint.rs @@ -175,7 +175,7 @@ macro_rules! make_uint { assert!($size <= 128); assert!(operands.len() >= 1); - assert!($size * operands.len() <= F::MODULUS_BIT_SIZE as usize); + assert!($size + ark_std::log2(operands.len()) <= F::MODULUS_BIT_SIZE); if operands.len() == 1 { return Ok(operands[0].clone());