pub fn diff_proofs(proof1: &Proof, proof2: &Proof) -> Vec<ProofDiff>Expand description
Compare two proofs and return their differences.
This function compares two proofs node-by-node and identifies:
- Nodes that exist only in the first proof
- Nodes that exist only in the second proof
- Nodes with matching IDs but different content
- Structural differences
§Arguments
proof1- The first proofproof2- The second proof
§Returns
A vector of differences found between the proofs
§Example
use oxiz_proof::proof::Proof;
use oxiz_proof::diff::diff_proofs;
let mut proof1 = Proof::new();
proof1.add_axiom("p");
proof1.add_axiom("q");
let mut proof2 = Proof::new();
proof2.add_axiom("p");
proof2.add_axiom("r");
let diffs = diff_proofs(&proof1, &proof2);
assert!(!diffs.is_empty());