Klar logoklaralpha

Formatting

Formatting command:

klar fmt <file.klar>
klar fmt <file.klar> --check

Current Behavior

The formatter currently works by parsing into AST and re-emitting code.

Important Caveat

Function and test bodies are currently emitted as placeholders in formatter output.

Use fmt with this behavior in mind until body-preserving formatting lands.

CI Usage

klar fmt --check exits non-zero when formatting differs from source.

Related Docs