Analyze
Use thru abi analyze when you need to understand how ABI types resolve before you generate code, publish an ABI, or debug a reflection failure.
Use This When
Section titled “Use This When”- you want to confirm imports and type resolution succeed
- you need the shared layout IR in JSON or protobuf form
- you want to preview generated footprint or validate helpers for one type
Choose another ABI command when:
- you want generated source code: Codegen
- you want to decode real bytes: Reflect
- you want to prepare a file for publishing: Prep for Publish
Syntax
Section titled “Syntax”thru abi analyze \ --files <FILE>... \ [--include-dir <DIR>...] \ [--print-ir] \ [--ir-format json|protobuf] \ [--print-footprint <TYPE>] \ [--print-validate <TYPE>]Important Flags
Section titled “Important Flags”| Flag | Use it for |
|---|---|
--print-ir | Print the shared layout IR after analysis. |
| `—ir-format json | protobuf` |
—print-footprint <TYPE> | Preview the generated legacy and IR footprint helpers for one type. |
—print-validate <TYPE> | Preview the generated legacy and IR validate helpers for one type. |
What It Prints
Section titled “What It Prints”Even without optional flags, analyze prints:
- loaded files and resolved packages
- discovered type definitions
- detailed type analysis from the resolved graph
Optional flags add focused output on top of that base analysis.
Minimal Patterns
Section titled “Minimal Patterns”thru abi analyze \ --files ./program.abi.yaml \ --include-dir ./abithru abi analyze \ --files ./program.abi.yaml \ --print-irthru abi analyze \ --files ./program.abi.yaml \ --print-footprint TransferArgs \ --print-validate TransferArgsanalyzeis a good first stop when codegen or reflection fails because it exercises the same import and type-resolution path.--print-iris the most useful flag when you need to compare multiple ABIs or inspect cross-language layout behavior.- If you only care whether an input file is ready for on-chain publishing, use Prep for Publish instead of loading the whole analysis output into context.