Skip to main content

format_workspace_macros

Function format_workspace_macros 

Source
pub fn format_workspace_macros(root: &Path, check: bool) -> Result<FmtReport>
Expand description

Formats all .rs files under root (or a single .rs file) in place or in --check mode.

§Arguments

  • &Path - Root directory or single Rust source file.
  • bool - When true, verifies formatting without modifying files and returns an error if changes are needed.

§Returns

  • io::Result<FmtReport> - Structured formatting report or error on I/O / check failure.