Skip to content

Commit

Permalink
Fix cargo clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
fractasy committed Nov 29, 2024
1 parent ccd7816 commit e83b11b
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions state-machines/arith/src/arith_full.rs
Original file line number Diff line number Diff line change
Expand Up @@ -191,8 +191,7 @@ impl<F: Field> ArithFullSM<F> {

timer_start_trace!(ARITH_PADDING);
let padding_offset = input.len();
let padding_rows: usize =
if num_rows > padding_offset { num_rows - padding_offset } else { 0 };
let padding_rows: usize = num_rows.saturating_sub(padding_offset);

if padding_rows > 0 {
let mut t: ArithRow<F> = Default::default();
Expand Down
2 changes: 1 addition & 1 deletion state-machines/arith/src/arith_range_table_helpers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ pub struct ArithRangeTableInputsIterator<'a> {
inputs: &'a ArithRangeTableInputs,
}

impl<'a> Iterator for ArithRangeTableInputsIterator<'a> {
impl Iterator for ArithRangeTableInputsIterator<'_> {
type Item = (usize, u64);

fn next(&mut self) -> Option<Self::Item> {
Expand Down
2 changes: 1 addition & 1 deletion state-machines/arith/src/arith_table_helpers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ pub struct ArithTableInputsIterator<'a> {
inputs: &'a ArithTableInputs,
}

impl<'a> Iterator for ArithTableInputsIterator<'a> {
impl Iterator for ArithTableInputsIterator<'_> {
type Item = (usize, u64);

fn next(&mut self) -> Option<Self::Item> {
Expand Down

0 comments on commit e83b11b

Please sign in to comment.