Skip to content

Commit

Permalink
Fix CI: broke on main following Rust 1.78.0 release today (nexus-xy…
Browse files Browse the repository at this point in the history
…z#156)

- Explicitly `#[allow(dead_code)]` on two currently unused trait
  functions.
- Use `Clone::clone_from` instead of `Clone::clone` (see lint:
  https://rust-lang.github.io/rust-clippy/master/index.html#/assigning_clones)
  • Loading branch information
mx00s authored May 2, 2024
1 parent 4dfa2b6 commit 92e1a9a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions nova/src/gadgets/nonnative/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ where
/// The mode of allocation is decided by `mode`.
///
/// This should not create any constraints.
#[allow(dead_code)]
fn new_variable_unconstrained<T: Borrow<V>>(
cs: impl Into<Namespace<F>>,
f: impl FnOnce() -> Result<T, SynthesisError>,
Expand Down
1 change: 1 addition & 0 deletions spartan/src/transcript.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ pub trait ProofTranscript<G: CurveGroup> {
fn append_scalar(&mut self, label: &'static [u8], scalar: &G::ScalarField);
fn append_scalars(&mut self, label: &'static [u8], scalars: &[G::ScalarField]);
fn append_point(&mut self, label: &'static [u8], point: &G);
#[allow(dead_code)]
fn append_points(&mut self, label: &'static [u8], points: &[G]);
fn challenge_scalar(&mut self, label: &'static [u8]) -> G::ScalarField;
fn challenge_vector(&mut self, label: &'static [u8], len: usize) -> Vec<G::ScalarField>;
Expand Down
2 changes: 1 addition & 1 deletion vm/src/circuit/r1cs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ impl R1CS {
let mut rv = format!("{i}");
for (n, j) in &self.vars {
if *j == i {
rv = n.clone();
rv.clone_from(n);
}
}
println!("{} * {} (name {})", v[i], self.w[i], rv);
Expand Down

0 comments on commit 92e1a9a

Please sign in to comment.