[KongchangAI]
ProductRust 格式化工具

rustfmt

The official code formatting tool for Rust, distributed with the Rust toolchain and invocable through cargo fmt. It automatically adjusts code formatting according to default rules and supports configuration via rustfmt.toml.

Timeline (last 90 days)

Oct 22

rustfmt alone cannot cover constraints on naming, doc comments, macro usage, or API design, requiring additional written guidelines.

Unverified50%
Oct 22

rustfmt is the official code formatting tool provided by Rust, distributed with the Rust toolchain, and can be invoked via cargo fmt.

Unverified50%
Oct 22

rustfmt supports adjusting some behavior through the rustfmt.toml configuration file, but its configurable options are relatively limited, and many options are still marked as unstable and can only be used under the nightly toolchain.

Unverified50%
Oct 17

The Syntax Gate module documentation specifies that the gate alone decides whether to reject a write; rustfmt is only responsible for formatting and has no blocking authority.

Unverified50%
Oct 17

After passing the Syntax Gate, if the file is a Rust file that was rustfmt-clean before the edit, the content to be written is first reformatted with rustfmt --edition 2024 to keep subsequent edit_file patch anchors stable.

Unverified50%
Oct 17

The Syntax Gate probes the rustfmt binary with a 5-second timeout and formats with a 10-second timeout; any failure (missing binary, non-zero exit, timeout, non-UTF-8 output) silently skips normalization and writes the raw text to disk.

Unverified50%
Oct 15

The tests and lints rustcoach runs use the real toolchain (cargo test, cargo clippy, rustfmt), not a simulated environment.

Unverified50%

All Facts (7)

Source Articles