diff --git a/snark-verifier/src/lib.rs b/snark-verifier/src/lib.rs index 87e18700..11187659 100644 --- a/snark-verifier/src/lib.rs +++ b/snark-verifier/src/lib.rs @@ -5,7 +5,7 @@ clippy::too_many_arguments, clippy::upper_case_acronyms )] -#![deny(missing_debug_implementations, missing_docs, unsafe_code)] +#![deny(missing_debug_implementations, missing_docs, unsafe_code, rustdoc::all)] pub mod cost; pub mod loader; diff --git a/snark-verifier/src/loader/evm/util/executor.rs b/snark-verifier/src/loader/evm/util/executor.rs index ab7c170f..de466c08 100644 --- a/snark-verifier/src/loader/evm/util/executor.rs +++ b/snark-verifier/src/loader/evm/util/executor.rs @@ -1,4 +1,5 @@ -//! Copied and modified from https://github.com/foundry-rs/foundry/blob/master/evm/src/executor/mod.rs +//! Copied and modified from +//! use crate::loader::evm::{Address, H256, U256}; use bytes::Bytes; @@ -725,7 +726,7 @@ impl ExecutorBuilder { self } - /// Initialize an [`Executor`]. + /// Initialize an `Executor`. pub fn build(self) -> Executor { Executor::new(self.debugger, self.gas_limit.unwrap_or(U256::MAX)) } diff --git a/snark-verifier/src/pcs.rs b/snark-verifier/src/pcs.rs index cdd098c8..535ebedf 100644 --- a/snark-verifier/src/pcs.rs +++ b/snark-verifier/src/pcs.rs @@ -166,7 +166,7 @@ where type Accumulator: Clone + Debug; /// Decode an [`AccumulatorEncoding::Accumulator`] from serveral - /// [`Loader::LoadedScalar`]s. + /// [`crate::loader::ScalarLoader::LoadedScalar`]s. fn from_repr(repr: &[&L::LoadedScalar]) -> Result; } diff --git a/snark-verifier/src/pcs/ipa.rs b/snark-verifier/src/pcs/ipa.rs index 4d870f1e..c782c65f 100644 --- a/snark-verifier/src/pcs/ipa.rs +++ b/snark-verifier/src/pcs/ipa.rs @@ -1,5 +1,5 @@ //! Inner product argument polynomial commitment scheme and accumulation scheme. -//! The notations are following https://eprint.iacr.org/2020/499.pdf. +//! The notations are following . use crate::{ loader::{native::NativeLoader, LoadedScalar, Loader, ScalarLoader}, @@ -311,7 +311,7 @@ where } } - /// Read [`AccumulationScheme::Proof`] from transcript. + /// Read [`crate::pcs::AccumulationScheme::Proof`] from transcript. pub fn read(svk: &IpaSuccinctVerifyingKey, transcript: &mut T) -> Result where T: TranscriptRead, diff --git a/snark-verifier/src/pcs/ipa/multiopen/bgh19.rs b/snark-verifier/src/pcs/ipa/multiopen/bgh19.rs index c8723dd0..a852267a 100644 --- a/snark-verifier/src/pcs/ipa/multiopen/bgh19.rs +++ b/snark-verifier/src/pcs/ipa/multiopen/bgh19.rs @@ -19,7 +19,8 @@ use std::{ }; /// Verifier of multi-open inner product argument. It is for the implementation -/// in [`halo2_proofs`], which is previously https://eprint.iacr.org/2019/1021. +/// in [`halo2_proofs`], which is previously +/// . #[derive(Clone, Debug)] pub struct Bgh19; diff --git a/snark-verifier/src/pcs/kzg/multiopen/bdfg21.rs b/snark-verifier/src/pcs/kzg/multiopen/bdfg21.rs index e618549d..3a448056 100644 --- a/snark-verifier/src/pcs/kzg/multiopen/bdfg21.rs +++ b/snark-verifier/src/pcs/kzg/multiopen/bdfg21.rs @@ -20,7 +20,7 @@ use std::{ /// Verifier of multi-open KZG. It is for the SHPLONK implementation /// in [`halo2_proofs`]. -/// Notations are following https://eprint.iacr.org/2020/081. +/// Notations are following . #[derive(Clone, Debug)] pub struct Bdfg21; diff --git a/snark-verifier/src/pcs/kzg/multiopen/gwc19.rs b/snark-verifier/src/pcs/kzg/multiopen/gwc19.rs index 358360fa..e5741163 100644 --- a/snark-verifier/src/pcs/kzg/multiopen/gwc19.rs +++ b/snark-verifier/src/pcs/kzg/multiopen/gwc19.rs @@ -16,7 +16,7 @@ use crate::{ /// Verifier of multi-open KZG. It is for the GWC implementation /// in [`halo2_proofs`]. -/// Notations are following https://eprint.iacr.org/2019/953.pdf. +/// Notations are following . #[derive(Clone, Debug)] pub struct Gwc19; diff --git a/snark-verifier/src/system/halo2/transcript/halo2.rs b/snark-verifier/src/system/halo2/transcript/halo2.rs index ef458434..8519a8ca 100644 --- a/snark-verifier/src/system/halo2/transcript/halo2.rs +++ b/snark-verifier/src/system/halo2/transcript/halo2.rs @@ -61,7 +61,7 @@ where R: Read, EccChip: NativeEncoding<'a, C>, { - /// Initialize [`EvmTranscript`] given [`Rc`]. + /// Initialize [`PoseidonTranscript`] given [`Rc`]. pub fn new(loader: &Rc>, stream: Value) -> Self { let buf = Poseidon::new(loader, R_F, R_P); Self { @@ -157,7 +157,7 @@ where impl PoseidonTranscript { - /// Initialize [`EvmTranscript`] given readable or writeable stream for + /// Initialize [`PoseidonTranscript`] given readable or writeable stream for /// verifying or proving with [`NativeLoader`]. pub fn new(stream: S) -> Self { Self { diff --git a/snark-verifier/src/util/msm.rs b/snark-verifier/src/util/msm.rs index 8fec380a..f68ce6f4 100644 --- a/snark-verifier/src/util/msm.rs +++ b/snark-verifier/src/util/msm.rs @@ -304,7 +304,7 @@ fn multi_scalar_multiplication_serial( } /// Multi-scalar multiplication algorithm copied from -/// https://github.com/zcash/halo2/blob/main/halo2_proofs/src/arithmetic.rs. +/// . pub fn multi_scalar_multiplication(scalars: &[C::Scalar], bases: &[C]) -> C::Curve { assert_eq!(scalars.len(), bases.len());