mirror of
https://github.com/arnaucube/hyperplonk.git
synced 2026-01-12 17:01:28 +01:00
a generic Trait for both ml and uni KZG (#43)
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
//! TODO(ZZ): decide which APIs need to be public.
|
||||
|
||||
use ark_ff::PrimeField;
|
||||
use ark_serialize::CanonicalSerialize;
|
||||
use merlin::Transcript;
|
||||
use std::marker::PhantomData;
|
||||
|
||||
@@ -67,6 +68,15 @@ impl<F: PrimeField> IOPTranscript<F> {
|
||||
self.append_message(label, &to_bytes!(field_elem)?)
|
||||
}
|
||||
|
||||
// Append the message to the transcript.
|
||||
pub fn append_serializable_element<S: CanonicalSerialize>(
|
||||
&mut self,
|
||||
label: &'static [u8],
|
||||
group_elem: &S,
|
||||
) -> Result<(), PolyIOPErrors> {
|
||||
self.append_message(label, &to_bytes!(group_elem)?)
|
||||
}
|
||||
|
||||
// Append a prover message to the transcript.
|
||||
pub(crate) fn append_prover_message(
|
||||
&mut self,
|
||||
|
||||
Reference in New Issue
Block a user