rust-types-and-apis
Installation
SKILL.md
Rust Types and APIs
Use this when the real question is how much of the design should be expressed in types, traits, and public signatures.
Working stance
- Make invalid states hard to represent before adding runtime checks.
- Keep public APIs narrower than internal helper code.
- Prefer concrete types until abstraction pressure is real.
- Use trait objects for extension seams and heterogeneity, not by reflex.
- Prefer typed domains and borrowed read-only inputs over stringly or collection-specific signatures.
- Accept broad inputs; return precise outputs.