nomic-fmt 0.3.0
Rapid releases, zero age, low downloads
“Canonical formatter for Nomic models”
AArch64 (ARM64) architecture stringComposite action step script body
SHA-256ac4b1484271a531a928ba7f6d0b8f0283e5a573c317a4d47c040c1c52c7912ad
MaleculeH(F)Md(Pa₂)
Evidence
1//! The formatter must be idempotent and must not change meaning: for every
2//! example model, format(format(x)) == format(x), and the formatted source
3//! parses to …
3:40… al once positions are ignored.
4
5use std::path::{Path, PathBuf};
6
7fn repo_root() -> PathBuf {
⋯4 lines
13:8… mut out: Vec<(String, String)> = Vec::new();
14 for folder in std::fs::read_dir(dir).unwrap().filter_map(|e| e.ok()).filter(|e| e.path().is_dir()) {
15 for e in std::fs::read_dir(folder.path()).unwrap(). …
43:23… json::to_value(model).unwrap();
44 strip_pos(&mut v);
45 v
46}
47
48#[test]
49fn formatting_preserves_the_ir_of_every_example() {
50 for (name, src) in examples() {
51 let formatted = nomic_fmt::form …
No evidence locations were recorded for this file. Raw result