padlock-output
Output formatters for padlock — a struct memory layout analyzer for C, C++, Rust, and Go.
This crate turns padlock-core Report and StructLayout types into human-readable or machine-readable output:
| Module | Function | Output |
|---|---|---|
summary |
render_report(&report) |
Terminal output, grouped by file with ── filename ── headers and :line locations |
json |
to_json(&report) |
JSON serialization of the full report |
sarif |
to_sarif(&report) |
SARIF 2.1.0 for GitHub/GitLab code-scanning integration |
diff |
render_diff(&layout) |
Unified diff of current vs optimal field order |
Usage
padlock-output is an internal library crate. To get formatted output, use the CLI:
Part of padlock
padlock-cli— CLI (padlock+cargo-padlockbinaries)padlock-core— IR, analysis passes, findingspadlock-source— Source analysis (C/C++/Rust/Go)padlock-dwarf— Binary analysis (DWARF/PDB)padlock-output— Output formatters (terminal/JSON/SARIF/diff) (this crate)padlock-macros— Compile-time layout assertions