From 22016b1b1304b4f47ece88f119a95039b523b0cc Mon Sep 17 00:00:00 2001 From: Thomas Coratger Date: Thu, 7 Nov 2024 12:15:05 +0100 Subject: [PATCH] revert Debug derive for Registers --- crates/brainfuck_vm/src/registers.rs | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/crates/brainfuck_vm/src/registers.rs b/crates/brainfuck_vm/src/registers.rs index 43d74e4..346ade9 100644 --- a/crates/brainfuck_vm/src/registers.rs +++ b/crates/brainfuck_vm/src/registers.rs @@ -3,7 +3,7 @@ use num_traits::identities::Zero; use stwo_prover::core::fields::m31::BaseField; -#[derive(PartialEq, Eq, Clone, Debug)] +#[derive(PartialEq, Eq, Clone)] pub struct Registers { /// Clock Cycle Counter pub clk: BaseField, @@ -51,6 +51,16 @@ impl std::fmt::Display for Registers { } } +impl std::fmt::Debug for Registers { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + write!( + f, + "clk:{}, ip:{}, ci:{}, ni:{}, mp:{}, mv:{}, mvi:{}", + self.clk, self.ip, self.ci, self.ni, self.mp, self.mv, self.mvi + ) + } +} + #[cfg(test)] mod tests { use super::*;