What problem does it solve?
Rust projects often struggle with ownership, lifetime, and concurrency bugs that lead to memory-safety issues, undefined behavior, and poor performance; this Skill provides patterns, checks, and idiomatic implementations to prevent those problems and produce reliable, maintainable Rust code.
Core Features & Use Cases
- Analyze ownership and lifetime relationships and propose explicit annotations when inference is insufficient.
- Design trait hierarchies, generics, and type-safe APIs that favor zero-cost abstractions.
- Implement async code with tokio, structure error handling using Result/Option and thiserror, and minimize unsafe usage with documented invariants.
- Validate code by running formatting, clippy, and test recommendations and provide test templates and benchmarks for production readiness.
- Use Case: Convert a prototype that misuses cloning and blocking I/O into an async tokio-based service with proper lifetimes, error types, and comprehensive unit and integration tests.
Quick Start
Implement a safe, idiomatic Rust module that fixes ownership issues, replaces unnecessary cloning with borrows, adds a custom error enum, and includes unit tests and cargo clippy/fmt instructions.