From b79ba8aa4c074b2cd09188f6f85ba68d6b80fe50 Mon Sep 17 00:00:00 2001 From: Tim Ruffing Date: Thu, 29 Jun 2023 16:44:22 +0200 Subject: [PATCH] field: Use `restrict` consistently in fe_sqrt That is, use it also in the definition and not only the declaration. I believe this was the intention of commit be82bd8e0347e090037ff1d30a22a9d614db8c9f, but it was omitted there. --- src/field_impl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/field_impl.h b/src/field_impl.h index 2a0fba20a..7f18ebdc9 100644 --- a/src/field_impl.h +++ b/src/field_impl.h @@ -44,7 +44,7 @@ SECP256K1_INLINE static int secp256k1_fe_equal_var(const secp256k1_fe *a, const return secp256k1_fe_normalizes_to_zero_var(&na); } -static int secp256k1_fe_sqrt(secp256k1_fe *r, const secp256k1_fe *a) { +static int secp256k1_fe_sqrt(secp256k1_fe * SECP256K1_RESTRICT r, const secp256k1_fe * SECP256K1_RESTRICT a) { /** Given that p is congruent to 3 mod 4, we can compute the square root of * a mod p as the (p+1)/4'th power of a. *