p3_challenger

Trait GrindingChallenger

Source
pub trait GrindingChallenger:
    CanObserve<Self::Witness>
    + CanSampleBits<usize>
    + Sync
    + Clone {
    type Witness: Field;

    // Required method
    fn grind(&mut self, bits: usize) -> Self::Witness;

    // Provided method
    fn check_witness(&mut self, bits: usize, witness: Self::Witness) -> bool { ... }
}

Required Associated Types§

Required Methods§

Source

fn grind(&mut self, bits: usize) -> Self::Witness

Provided Methods§

Source

fn check_witness(&mut self, bits: usize, witness: Self::Witness) -> bool

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<F, Inner> GrindingChallenger for SerializingChallenger32<F, Inner>
where F: PrimeField32, Inner: CanSample<u8> + CanObserve<u8> + Clone + Send + Sync,

Source§

impl<F, Inner> GrindingChallenger for SerializingChallenger64<F, Inner>
where F: PrimeField64, Inner: CanSample<u8> + CanObserve<u8> + Clone + Send + Sync,

Source§

impl<F, P, const WIDTH: usize, const RATE: usize> GrindingChallenger for DuplexChallenger<F, P, WIDTH, RATE>

Source§

impl<F, PF, P, const WIDTH: usize, const RATE: usize> GrindingChallenger for MultiField32Challenger<F, PF, P, WIDTH, RATE>