fn create_random_proof<E, C, R, P: ParameterSource<E>>(
    circuit: C,
    params: P,
    rng: &mut R,
) -> Result<(Proof<E>, Duration, Duration), SynthesisError>
where
    E: Engine,
    C: Circuit<E>,
    R: Rng,
{
    let synth_start = Instant::now();
    let r = rng.gen();
    let s = rng.gen();
    let prover = prepare_prover(circuit)?;
    let synth_end = Instant::now();

    let crypto_start = Instant::now();
    let proof = prover.create_proof(params, r, s)?;
    let crypto_end = Instant::now();

    Ok((proof, synth_end - synth_start, crypto_end - crypto_start))
}
/// A copy of the `create_random_proof` procedure of bellman.
/// Returns the proof, the time spent synthesizing the circuit and its inputs, and the time spent
/// doing cryptography.
A copy of the `create_random_proof` procedure of bellman.
Returns the proof, the time spent synthesizing the circuit and its inputs, and the time spent
doing cryptography.
A copy of the ` create_random_proof ` procedure of bellman . Returns the proof the time spent synthesizing the circuit and its inputs and the time spent doing cryptography .
fn create_random_proof<E, C, R, P: ParameterSource<E>>(
    circuit: C,
    params: P,
    rng: &mut R,
) -> Result<(Proof<E>, Duration, Duration), SynthesisError>
where
    E: Engine,
    C: Circuit<E>,
    R: Rng,
{
    let synth_start = Instant::now();
    let r = rng.gen();
    let s = rng.gen();
    let prover = prepare_prover(circuit)?;
    let synth_end = Instant::now();
    let crypto_start = Instant::now();
    let proof = prover.create_proof(params, r, s)?;
    let crypto_end = Instant::now();
    Ok((proof, synth_end - synth_start, crypto_end - crypto_start))
}
fn create_random_proof < E , C , R , P : ParameterSource < E > > ( circuit : C , params : P , rng : & mut R , ) -> Result < ( Proof < E > , Duration , Duration ) , SynthesisError > where E : Engine , C : Circuit < E > , R : Rng , { let synth_start = Instant :: now ( ) ; let r = rng . gen ( ) ; let s = rng . gen ( ) ; let prover = prepare_prover ( circuit ) ? ; let synth_end = Instant :: now ( ) ; let crypto_start = Instant :: now ( ) ; let proof = prover . create_proof ( params , r , s ) ? ; let crypto_end = Instant :: now ( ) ; Ok ( ( proof , synth_end - synth_start , crypto_end - crypto_start ) ) }
A copy of the `create_random_proof` procedure of bellman.
A copy of the ` create_random_proof ` procedure of bellman .
circuit
C
params
P
rng
&mut R
circuit
C
params
P
rng
&mut R