Skip to content

Commit

Permalink
fix debug assertion
Browse files Browse the repository at this point in the history
  • Loading branch information
tamirhemo committed Oct 10, 2024
1 parent 1f6be4b commit da76d25
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion crates/core/machine/src/program/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,10 @@ impl<F: PrimeField> MachineAir<F> for ProgramChip {
}

fn generate_preprocessed_trace(&self, program: &Self::Program) -> Option<RowMajorMatrix<F>> {
debug_assert!(!program.instructions.is_empty(), "empty program");
debug_assert!(
!program.instructions.is_empty() || program.preprocessed_shape.is_some(),
"empty program"
);
let mut rows = program
.instructions
.iter()
Expand Down

0 comments on commit da76d25

Please sign in to comment.