Fast Rust compilation check. Use during active coding for quick type-check feedback without full codegen. Prefer over `cargo build` when you only need to verify types, borrows, and syntax.
Fast Rust compilation check. Use during active coding for quick type-check feedback without full codegen. Prefer over `cargo build` when you only need to verify types, borrows, and syntax.
Checking
cargo check
Workspace
cargo check --workspace
Specific package
cargo check -p <package>
Release mode
cargo check --release
Gotchas
--workspace checks all packages; --all is deprecated — always use --workspace.
Much faster than cargo build (skips codegen) but does not verify linking.
Use during active editing cycles; switch to cargo build before claiming done.
--all-targets includes tests, benches, and examples.