Skip to main content
Jeden Skill in Manus ausführen
mit einem Klick

api-typestate

Sterne17
Forks0
Aktualisiert3. Juli 2026 um 07:45

Use the typestate pattern to encode state-machine invariants in Rust's type system instead of runtime checks. Apply when designing or reviewing any Rust type that tracks a lifecycle/mode (connection, transaction, builder, session, handshake, subscription) and currently guards operations with an enum field plus runtime `if`/`match` checks. Also use when reviewing PRs that add a new "invalid state" error variant to an existing struct.

Installation

Mit Codex oder Claude installieren Kopieren Sie diesen Prompt, fügen Sie ihn in Codex, Claude oder einen anderen Assistant ein und lassen Sie die Skill-Seite prüfen und installieren.

SKILL.md
readonly