From 9feead7d4dbad951e6aa1d572230b1c098ec8040 Mon Sep 17 00:00:00 2001 From: Ivan Oleynikov Date: Thu, 23 Nov 2023 09:25:49 +0100 Subject: [PATCH] Make KzgDecidingKey fields public (#56) Fixes #55. This commit enables users to re-use more of snark-verifier code when implementing impl AccumulationDecider<_, MyLoader> for KzgAs<_, _> in order to define their own Loader and make it work with KZG10. The field `svk` was already exported through `impl AsRef>`, but this commit additionally defines it as `pub` for consistency with `g2` and `s_g2` fields. --- snark-verifier/src/pcs/kzg/decider.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/snark-verifier/src/pcs/kzg/decider.rs b/snark-verifier/src/pcs/kzg/decider.rs index 085a19cd..eb7e84a7 100644 --- a/snark-verifier/src/pcs/kzg/decider.rs +++ b/snark-verifier/src/pcs/kzg/decider.rs @@ -4,11 +4,12 @@ use std::marker::PhantomData; /// KZG deciding key. #[derive(Debug, Clone, Copy)] pub struct KzgDecidingKey { - svk: KzgSuccinctVerifyingKey, + /// KZG succinct verifying key. + pub svk: KzgSuccinctVerifyingKey, /// Generator on G2. - g2: M::G2Affine, + pub g2: M::G2Affine, /// Generator to the trusted-setup secret on G2. - s_g2: M::G2Affine, + pub s_g2: M::G2Affine, _marker: PhantomData, }