Skip to content

Commit

Permalink
Pretty print the json
Browse files Browse the repository at this point in the history
  • Loading branch information
mwillsey committed Jan 12, 2024
1 parent 8d53c83 commit 9629c74
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ impl EGraph {
#[cfg(feature = "serde")]
pub fn to_json_file(&self, path: impl AsRef<std::path::Path>) -> std::io::Result<()> {
let file = std::fs::File::create(path)?;
serde_json::to_writer(std::io::BufWriter::new(file), self)?;
serde_json::to_writer_pretty(std::io::BufWriter::new(file), self)?;
Ok(())
}

Expand Down

0 comments on commit 9629c74

Please sign in to comment.