From 831a6718726f74a19102a570deb30522378ca060 Mon Sep 17 00:00:00 2001 From: Daniel Lubarov Date: Fri, 19 Aug 2022 10:35:02 -0700 Subject: [PATCH] Tweak comments --- field/src/goldilocks_extensions.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/field/src/goldilocks_extensions.rs b/field/src/goldilocks_extensions.rs index e684c7cb..2175494f 100644 --- a/field/src/goldilocks_extensions.rs +++ b/field/src/goldilocks_extensions.rs @@ -112,14 +112,14 @@ impl Mul for QuinticExtension { * result coefficient is necessary. */ -/// Return a, b such that a + b*2^128 = 3*x with a < 2^128 and b < 2^32. +/// Return `a`, `b` such that `a + b*2^128 = 3*(x + y*2^128)` with `a < 2^128` and `b < 2^32`. #[inline(always)] fn u160_times_3(x: u128, y: u32) -> (u128, u32) { let (s, cy) = x.overflowing_add(x << 1); (s, 3 * y + (x >> 127) as u32 + cy as u32) } -/// Return a, b such that a + b*2^128 = 7*x with a < 2^128 and b < 2^32. +/// Return `a`, `b` such that `a + b*2^128 = 7*(x + y*2^128)` with `a < 2^128` and `b < 2^32`. #[inline(always)] fn u160_times_7(x: u128, y: u32) -> (u128, u32) { let (d, br) = (x << 3).overflowing_sub(x);