From 2e591d543ea8d62e83068d310cdc64047466c526 Mon Sep 17 00:00:00 2001 From: ambrona Date: Tue, 23 Apr 2024 16:11:23 +0200 Subject: [PATCH] minor --- halo2_proofs/src/plonk/keygen.rs | 42 ++++++++++++++++---------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/halo2_proofs/src/plonk/keygen.rs b/halo2_proofs/src/plonk/keygen.rs index 9aabe6d9a5..2a0f584701 100644 --- a/halo2_proofs/src/plonk/keygen.rs +++ b/halo2_proofs/src/plonk/keygen.rs @@ -78,9 +78,9 @@ impl Assignment for Assembly { A: FnOnce() -> AR, AR: Into, { - if !self.usable_rows.contains(&row) { - return Err(Error::not_enough_rows_available(self.k)); - } + // if !self.usable_rows.contains(&row) { + // return Err(Error::not_enough_rows_available(self.k)); + // } self.selectors[selector.0][row] = true; @@ -88,9 +88,9 @@ impl Assignment for Assembly { } fn query_instance(&self, _: Column, row: usize) -> Result, Error> { - if !self.usable_rows.contains(&row) { - return Err(Error::not_enough_rows_available(self.k)); - } + // if !self.usable_rows.contains(&row) { + // return Err(Error::not_enough_rows_available(self.k)); + // } // There is no instance in this context. Ok(Value::unknown()) @@ -126,9 +126,9 @@ impl Assignment for Assembly { A: FnOnce() -> AR, AR: Into, { - if !self.usable_rows.contains(&row) { - return Err(Error::not_enough_rows_available(self.k)); - } + // if !self.usable_rows.contains(&row) { + // return Err(Error::not_enough_rows_available(self.k)); + // } *self .fixed @@ -146,9 +146,9 @@ impl Assignment for Assembly { right_column: Column, right_row: usize, ) -> Result<(), Error> { - if !self.usable_rows.contains(&left_row) || !self.usable_rows.contains(&right_row) { - return Err(Error::not_enough_rows_available(self.k)); - } + // if !self.usable_rows.contains(&left_row) || !self.usable_rows.contains(&right_row) { + // return Err(Error::not_enough_rows_available(self.k)); + // } self.permutation .copy(left_column, left_row, right_column, right_row) @@ -160,9 +160,9 @@ impl Assignment for Assembly { from_row: usize, to: Value>, ) -> Result<(), Error> { - if !self.usable_rows.contains(&from_row) { - return Err(Error::not_enough_rows_available(self.k)); - } + // if !self.usable_rows.contains(&from_row) { + // return Err(Error::not_enough_rows_available(self.k)); + // } let col = self .fixed @@ -237,9 +237,9 @@ where circuit.params(), ); - if (params.n() as usize) < cs.minimum_rows() { - return Err(Error::not_enough_rows_available(params.k())); - } + // if (params.n() as usize) < cs.minimum_rows() { + // return Err(Error::not_enough_rows_available(params.k())); + // } let mut assembly: Assembly = Assembly { k: params.k(), @@ -310,9 +310,9 @@ where let cs = cs; - if (params.n() as usize) < cs.minimum_rows() { - return Err(Error::not_enough_rows_available(params.k())); - } + // if (params.n() as usize) < cs.minimum_rows() { + // return Err(Error::not_enough_rows_available(params.k())); + // } let mut assembly: Assembly = Assembly { k: params.k(),