Skip to content

Commit

Permalink
validation & deserialization match
Browse files Browse the repository at this point in the history
  • Loading branch information
neotheprogramist committed Jan 10, 2024
1 parent 96d2ed3 commit cd9a950
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 7 deletions.
2 changes: 0 additions & 2 deletions src/deserialization/fri.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ impl IntoFriWitness of Into<FriWitnessWithSerde, FriWitness> {
},
}
);

i += 1;
};

FriWitness { layers: layers.span(), }
Expand Down
2 changes: 0 additions & 2 deletions src/deserialization/stark.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,6 @@ impl IntoStarkUnsentCommitment of Into<StarkUnsentCommitmentWithSerde, StarkUnse
struct StarkWitnessWithSerde {
traces_decommitment: TracesDecommitmentWithSerde,
traces_witness: TracesWitnessWithSerde,
interaction: TableCommitmentWitnessWithSerde,
composition_decommitment: TableDecommitmentWithSerde,
composition_witness: TableCommitmentWitnessWithSerde,
fri_witness: FriWitnessWithSerde,
Expand All @@ -176,7 +175,6 @@ impl IntoStarkWitness of Into<StarkWitnessWithSerde, StarkWitness> {
StarkWitness {
traces_decommitment: self.traces_decommitment.into(),
traces_witness: self.traces_witness.into(),
interaction: self.interaction.into(),
composition_decommitment: self.composition_decommitment.into(),
composition_witness: self.composition_witness.into(),
fri_witness: self.fri_witness.into(),
Expand Down
6 changes: 4 additions & 2 deletions src/lib.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,11 @@ mod stark;
mod table_commitment;
mod vector_commitment;

use cairo_verifier::deserialization::stark::StarkProofWithSerde;
use cairo_verifier::{deserialization::stark::StarkProofWithSerde, stark::StarkProof,};

fn main(x: Array<felt252>) {
let mut x_span = x.span();
let stark_proof: StarkProofWithSerde = Serde::deserialize(ref x_span).unwrap();
let stark_proof: StarkProof = Serde::<StarkProofWithSerde>::deserialize(ref x_span)
.unwrap()
.into();
}
1 change: 0 additions & 1 deletion src/stark.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ struct StarkUnsentCommitment {
struct StarkWitness {
traces_decommitment: TracesDecommitment,
traces_witness: TracesWitness,
interaction: TableCommitmentWitness,
composition_decommitment: TableDecommitment,
composition_witness: TableCommitmentWitness,
fri_witness: FriWitness,
Expand Down

0 comments on commit cd9a950

Please sign in to comment.