Skip to content

Commit

Permalink
Cleanups and minor refactors.
Browse files Browse the repository at this point in the history
Co-authored-by: Jack Grigg <[email protected]>
  • Loading branch information
therealyingtong and str4d committed Jun 29, 2021
1 parent 9b47bd0 commit 12cef17
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 10 deletions.
6 changes: 2 additions & 4 deletions src/circuit/gadget/sinsemilla.rs
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,8 @@ where
Self {
chip,
inner: pieces
.iter()
.map(|piece| piece.inner.clone())
.into_iter()
.map(|piece| piece.inner)
.collect::<Vec<_>>()
.into(),
}
Expand Down Expand Up @@ -354,13 +354,11 @@ mod tests {
meta.fixed_column(),
meta.fixed_column(),
];
let constants_3 = meta.fixed_column();

let perm = meta.permutation(
&advices
.iter()
.map(|advice| (*advice).into())
.chain(Some(constants_3.into()))
.chain(constants_1.iter().map(|fixed| (*fixed).into()))
.chain(constants_2.iter().map(|fixed| (*fixed).into()))
.collect::<Vec<_>>(),
Expand Down
6 changes: 0 additions & 6 deletions src/circuit/gadget/sinsemilla/chip.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,6 @@ pub struct SinsemillaConfig {
pub(super) lookup_config_4: LookupRangeCheckConfig<pallas::Base, { sinsemilla::K }>,
}

impl SinsemillaConfig {
pub fn advices(&self) -> [Column<Advice>; 5] {
[self.bits, self.lambda_1, self.lambda_2, self.x_a, self.x_p]
}
}

#[derive(Eq, PartialEq, Clone, Debug)]
pub struct SinsemillaChip {
config: SinsemillaConfig,
Expand Down

0 comments on commit 12cef17

Please sign in to comment.