CATEGORY

Rust patterns 3,906 crates

Data as of 2026-07-25 (crates.io database dump, timestamp 2026-07-25T02:00:36Z). Source: crates.io · db-dump.tar.gz · methodology & corrections.

patchable-macroMacro suite for the patchable crate: enables model with #[patchable_model] and automatic trait derives for Patchable and Patch.437MIT OR Apache-2.0Data structuresRust patterns anylmThe universal API for all AI services that you know435MITDevelopment toolsRust patterns oopsie-coreCore error types and trace capture for the oopsie error-handling library434MIT OR Apache-2.0Development tools::DebuggingRust patterns aridAn ergonomic object-model for Rust.432MITRust patterns typeshaper-macrosProc-macro internals for the typeshaper crate — do not use directly432MIT OR Apache-2.0Development toolsRust patterns karpal-schubert-typesSchubert intersection type system for the Industrial Algebra ecosystem426Apache-2.0No standard libraryRust patterns karpal-opticsProfunctor optics (Lens, Prism) for the Industrial Algebra ecosystem424Apache-2.0No standard libraryRust patterns vouchedA derive macro for validated tuple-struct wrappers.424MIT OR Apache-2.0Rust patterns dizzyMacros for safely interacting with DST newtypes423MITNo standard libraryRust patterns bauerA derive macro for automatically generating builders423Apache-2.0Data structuresDevelopment tools annotate-buildBuild-script support for generating annotate environments422MITDevelopment toolsRust patterns return-okMacros for dealing with Options and Results where you shouldn't421MIT OR Apache-2.0Rust patterns constrangeiterConstant iterators for ranges419MITAlgorithmsData structures unwrap_unreachableProvides `Option::unreachable()` and `Result::unreachable()` methods417MITRust patterns smart-formatComposable, zero-allocation Display formatting combinators for Rust.417MIT/Apache-2.0Rust patternsText processing rs-schema-deriveProcedural macros to derive `rs-schema` types from Rust code structures.415MIT OR Apache-2.0Rust patterns no-copyA simple packer, but no implement copy412MITData structuresNo standard library itemize_derive_implImplementation details for itemize derive macros412MIT OR Apache-2.0Rust patterns perfectionistAdditional linting rules for Rust projects412MITDevelopment toolsRust patterns bind2Generate some let statements, similar to bind, but very lightweight409MITRust patterns siSI and IEC prefixes406Apache-2.0 OR MITMathematicsNo standard library::No dynamic allocation semisafeSemi-safe utilities for performance-critical Rust405MIT or Apache-2.0Development toolsRust patterns structible-macrosProc macros for structible399MITDevelopment tools::Procedural macro helpersRust patterns scopeguard-liteA lightweight way to defer execution of a block to the end of the scope, and to run code during an unwind.396MIT OR Apache-2.0No standard libraryNo standard library::No dynamic allocation bilockA minimal spin-lock based two-handle `Arc<Mutex<T>>` replacement388ISC OR MIT OR Apache-2.0Data structuresNo standard library active-reportingA custom error wrapper for detailed logs385MITCachingDevelopment tools::Debugging enum_isEnum helper derive: auto-generate is_<variant>() methods for enums384MITRust patterns functora-taggedLightweight, macro-free newtypes with refinement and derived traits.383MITData structuresRust patterns dynpatch-macroProcedural macros for dynpatch - #[patchable], #[patch_impl], #[patch_trait]380MITDevelopment toolsRust patterns error-locationA lightweight utility for capturing and displaying error locations in Rust380MITDevelopment tools::DebuggingRust patterns typeshaperTypeScript utility-type idioms (Omit, Pick, Merge, Partial…) for Rust structs — one-line type algebra expressions379MIT OR Apache-2.0Development toolsRust patterns annotateAnnotation framework for Rust functions and modules376MITDevelopment toolsRust patterns infiltraitA procedural macro that automatically generates trait definitions from implementation blocks374MIT OR Apache-2.0Rust patterns other-errorSmall wrapper for sharing or combining errors373Apache-2.0 OR MITNo standard library::No dynamic allocationRust patterns komadoriMulti-reduction library. Provides a composable, declarative way to consume an iterator369MIT OR Apache-2.0AlgorithmsNo standard library functoraMissing pieces of the Rust standard library.368MITRust patterns spread_patternsSome macros to make it easier to do pattern matching over strings, arrays, etc.365MITDevelopment toolsEncoding sealedstructGenerate boilerplate code to transition from raw (unchecked) structs to sealed (validated) structs363MITDevelopment toolsRust patterns action_dispatch_core通用的基于属性宏的 Action 注册与分发系统361MIT OR Apache-2.0AsynchronousRust patterns nekopas2rust-macros...360MIT OR Apache-2.0Development toolsRust patterns rootcause-preformatPreformatting support for the rootcause error reporting library359MIT/Apache-2.0Rust patterns action_dispatch_macro通用的基于属性宏的 Action 注册与分发系统357MIT OR Apache-2.0AsynchronousRust patterns oopsieErgonomic, structured error handling: context selectors, traced errors, and rich colorized reports355MIT OR Apache-2.0Development tools::DebuggingRust patterns itemizeTraits for flattening heterogeneous, nested inputs into a single iterator354MIT OR Apache-2.0Rust patterns syan-macroSyntactic and structural parser fundamentals, reimplementing syn crate351MITData structuresNo standard library::No dynamic allocation struct-to-enumDerive macros to generate enums from struct fields - compile-time safe field selection and dispatch351MIT OR Apache-2.0Rust patterns ai-quick-errorA no_std fork of quick-error350MIT/Apache-2.0Rust patterns charon-errorStructured error and panic handling with rich reports and bug reporting functionality348MIT OR Apache-2.0Development tools::DebuggingRust patterns structural-typingType-level field presence tracking for Rust structs, inspired by TypeScript348MIT OR Apache-2.0Development toolsNo standard library anon_iterReturn different Iterator types from function returning `-> impl Iterator`345MIT OR Apache-2.0Data structuresRust patterns error-kitA comprehensive error handling library for Rust applications343BSD-3-ClauseRust patterns anvilforge-spark-deriveProc macros for Spark: #[derive(Spark)], #[spark::action], #[spark::mount], #[spark::updated], #[spark::on].342MITRust patternsWeb programming bronzite-client🔮 Client library for querying the Bronzite compile-time reflection daemon from proc-macros341MIT OR Apache-2.0Development tools::Procedural macro helpersRust patterns anvilforge-cast-deriveCast ORM derive macros: #[derive(Model)], #[has_many], #[belongs_to], #[scope].341MITDatabase interfacesRust patterns const-toolsUtilities to help write safe const fns such as destructuring and array operations.339MIT OR Apache-2.0Rust patterns stackbox_2`&own`ing references in stable Rust - no_std-friendly Box332Zlib OR MIT OR Apache-2.0No standard libraryRust patterns optionize-macrosThe procedural macro engine powering the optionize crate329MITConfigurationRust patterns error-accumulatorUtility to make it easier for developers to write input validation.328MIT OR Apache-2.0Rust patterns flowstateWorkflow runtime powered by finite state machines.328MIT OR Apache-2.0Rust patterns karpal-freeFree constructions (Coyoneda, Yoneda) for the Industrial Algebra ecosystem327Apache-2.0No standard libraryRust patterns oyui-rune-actionsA declarative framework for defining nested action hierarchies, generating handler traits, and registering bindings automatically…325MIT OR Apache-2.0Development toolsRust patterns async-dropxA practical crate for async destructors in Rust323MITAsynchronousRust patterns stable_identifierConvenience library for working with identifier types323MITData structuresRust patterns structibleA macro for defining virtual structs backed by maps320MITData structuresRust patterns read-only-deriveProc-macro support crate for read-only319MIT OR Apache-2.0Development tools::Procedural macro helpersRust patterns audit-trailStructured audit logging with tamper-evident chaining. Every write produces a cryptographically linked record (hash chain).…319Apache-2.0 OR MITCryptographyRust patterns decimal_scaled_macrosCompile-time decimal literal proc-macros for the decimal-scaled crate — one per width tier (`d18!`, `d38!`, `d57!`, `d76!`,…313MIT OR Apache-2.0MathematicsNo standard library field-kinds-deriveProc-macro implementation for field-kinds311MITDevelopment tools::Procedural macro helpersRust patterns enum-from-discriminant-deriveMacro to implement TryFrom<Integers> for enum discriminants303UnlicenseRust patterns tendrilsTiny, flexible helpers for managing shared state (Arc<Mutex<T>> / Arc<RwLock<T>>) safely in async Rust.302MITAsynchronousConcurrency itemize_deriveDerive macros for the itemize crate301MIT OR Apache-2.0Rust patterns arity-indexBounds-check-free niche integer index types (U3-U7) with double-ended range iterators299MITData structuresNo standard library duration-extErgonomic extension trait for creating std::time::Duration from numeric literals294GPL-3.0-onlyDate and timeRust patterns karpal-arrowCategory and Arrow hierarchy for the Industrial Algebra ecosystem293Apache-2.0No standard libraryRust patterns fuzzy-cmpFast, lightweight fuzzy string comparison library for Rust with multiple similarity strategies: byte-level, word-level,…288MITDevelopment toolsRust patterns const-map-arrayMap arrays in a const context.287MIT OR Apache-2.0Rust patterns typeshift-deriveProc-macro derive support for typeshift284MITDevelopment toolsRust patterns hsmc-macrosProcedural macro implementation for the hsmc crate.283MITDevelopment tools::Procedural macro helpersRust patterns read-onlyRead-only field exposure and safe composition helpers via proc macros282MIT OR Apache-2.0Development tools::Procedural macro helpersRust patterns errcraftBeautiful, structured, and colorful error handling for Rust.279MITDevelopment tools::DebuggingRust patterns better-conversionsSafe and explicit numeric conversions with range and precision checking279MIT OR Apache-2.0MathematicsNo standard library oyui-taskerA macro-driven event loop and background task orchestration framework for asynchronous Rust applications.278MIT OR Apache-2.0AsynchronousRust patterns optionizeA procedural macro to generate optionized versions of structs for partial configurations, updates, and builders277MITConfigurationRust patterns anvilforge-deriveProc macros for Anvilforge: FormRequest, Job, Migration, Listener.277MITRust patternsWeb programming changeset-sagaSaga pattern for atomic multi-step operations273MITRust patterns tryphonType-safe configuration loading from environment variables using derive macros273MITConfigurationDevelopment tools qail-macroProcedural macros for QAIL - compile-time validated database queries272MITDatabase interfacesRust patterns event_chainsA flexible event processing pipeline with middleware support272MITDevelopment toolsDevelopment tools::Testing facet-mietteDerive miette::Diagnostic for facet types - rich error reporting with source spans272MIT OR Apache-2.0Development toolsRust patterns bento-kitA bento box of common Rust utilities: id generation, timing, masking269MIT OR Apache-2.0Development toolsRust patterns decycle-implInternal implementation for decycle macros266MITDevelopment tools::Procedural macro helpersRust patterns nohasherNo-op hasher265MIT OR Apache-2.0No standard libraryRust patterns okerrErgonomic result / error handling helpers built on anyhow and thiserror.265MITData structuresRust patterns uor-prism-verifyThe Prism replay façade: a thin verification surface re-exporting `certify_from_trace`, `Certified`, and the wire-format types…265MITNo standard libraryRust patterns n-observerAn async/await observer pattern implementation.263MIT OR Apache-2.0Rust patterns loose_enumA macro for defining loose repr enums.260MIT OR Apache-2.0No standard libraryNo standard library::No dynamic allocation partial-cmp-deriveDerive PartialEq, Eq, PartialOrd, Ord, and Hash with fine-grained control over field comparison257MITDevelopment tools::Procedural macro helpersRust patterns disDis(playish): Wrappers, trait extensions and asserts to wrap type(s) implementing Display and an optional extra. Use with…254BSD-2-Clause OR Apache-2.0 OR MITDevelopment toolsNo standard library capsec-tokioAsync capability-gated wrappers for tokio — the async counterpart to capsec-std253Apache-2.0AsynchronousRust patterns varchainAsync-only chain-based variable lookup engine, support no_std with alloc.252MITAsynchronousNo standard library xiaoyong-valueCollection of sharing state primitives for async contexts (both Sync and !Sync)250MIT OR Apache-2.0AsynchronousData structures reliakit-coreShared building blocks for Reliakit: a clock-agnostic Clock trait with manual and monotonic clocks. no_std and zero-dependency.250MITDate and timeNo standard library reliakit-collectionsBounded and reliability-oriented collection types for Rust.247MITData structuresNo standard library crdt-migrate-macrosProc macros for crdt-migrate: #[crdt_schema] and #[migration]246MIT OR Apache-2.0Database interfacesRust patterns bearivesome derive macros i wrote245non-standardRust patterns capsecCompile-time capability-based security for Rust244Apache-2.0Development toolsRust patterns aerroCross-service gRPC error framework for Rust.244MIT OR Apache-2.0Network programmingRust patterns czsc-deriveInternal proc-macro of the czsc framework (普通用户请用 `czsc` facade): #[derive(CZSCErrorDerive)] auto-implements From<anyhow::Error>…244MITDevelopment tools::Procedural macro helpersRust patterns backerror-macrosJava style backtrace for Rust243Apache-2.0Development tools::DebuggingNo standard library karpal-recursionRecursion schemes (cata, ana, hylo, para, apo, histo, futu, zygo, chrono) for the Industrial Algebra ecosystem242Apache-2.0No standard libraryRust patterns locksThread-safe type wrappers241MITConcurrencyData structures pick-by-autoderefPick by autoderef: a compile-time dispatch by priority241non-standardAlgorithmsDevelopment tools tower-resilience-outlierOutlier detection pattern for Tower services - fleet-aware instance ejection241MIT OR Apache-2.0Network programmingRust patterns qubit-argumentStructured, ownership-preserving argument validation for Rust applications238Apache-2.0Development toolsRust patterns reliakit-circuitClock-agnostic circuit breaker for fault isolation and fast failure. no_std and zero-dependency.237MITAlgorithmsNo standard library pud-macrosGenerate typed, composable, no-std-friendly modifications (“puds”) for Rust structs.236WTFPLData structuresRust patterns bwu_reduxAsync Redux-style state management for Rust, native and WASM234MIT OR Apache-2.0AsynchronousRust patterns ddd_cqrs_esA lightweight DDD, CQRS, and Event Sourcing framework for Rust232MITDevelopment toolsRust patterns judiciousA rate-limiting library that enforces a cooldown period after a resource has been used (return-time based).232non-standardAsynchronousRust patterns error-collectionA generic collection around dynamic errors230MIT OR Apache-2.0Development tools::DebuggingRust patterns fack-coreCore trait definitions for fack error handling library230GPL-3.0No standard libraryRust patterns tramli-pluginsPlugin pack for tramli — audit, eventstore, observability, resume, idempotency, hierarchy, diagram, docs, lint, testing, subflow229MITData structuresRust patterns pyenum-derive#[derive(PyEnum)] procedural macro for the `pyenum` crate.228MITAPI bindingsRust patterns any-trait-macromacros used by the any-trait crate227EUPL-1.2No standard libraryRust patterns hsmcHierarchical state machines (statecharts) with a declarative proc macro.227MITAsynchronousEmbedded development bronzite-macros🔮 Proc-macros for Bronzite compile-time type reflection - inspect traits, fields, and methods at compile time226MIT OR Apache-2.0Development tools::Procedural macro helpersRust patterns mce-libMarkdown Code Extractor library (part of mce): Collect code blocks from your README.md (or another Markdown file). Optional…225BSD-2-Clause OR Apache-2.0 OR MITDevelopment toolsDevelopment tools::Testing rakka-macrosProcedural macros for rakka — `#[derive(Actor)]`, `props!`, `#[derive(Receive)]`.221Apache-2.0ConcurrencyRust patterns karpal-effectMonad transformers and effect system for the Industrial Algebra ecosystem220Apache-2.0No standard libraryRust patterns junkdrawerA crate for all kinds of utilities.216MIT OR Apache-2.0Data structuresRust patterns placid-macroSeparated ownership and in-place construction in Rust214MIT OR Apache-2.0No standard libraryRust patterns decycle-macroSolve circular trait obligation210MITDevelopment tools::Procedural macro helpersRust patterns rt-events-dagType-safe event DAG topology. Edges are event types; structural checks are walks.210MIT OR Apache-2.0Data structuresRust patterns iter_seq_extIterator extension for sequential items.209MITNo standard libraryRust patterns result-aat-coreThe Infomation and Result Trace crate207Apache-2.0Development tools::DebuggingNo standard library reliakit-deriveDerive macros for reliakit traits, implemented with only the standard library proc-macro API and no third-party dependencies.207MITDevelopment tools::Procedural macro helpersEncoding trame-runtimeRuntime traits and implementations for trame205MIT OR Apache-2.0Development toolsRust patterns action_dispatch通用的基于属性宏的 Action 注册与分发系统,支持正则匹配、优先级、全局同步执行模式205MIT OR Apache-2.0AsynchronousRust patterns charon-loggingStructured logging setup using tracing, with span trace capture via tracing-error204MIT OR Apache-2.0Development tools::DebuggingRust patterns collect_failableA trait for collecting values into a container which has an invariant to uphold and whose construction may fail204MIT OR Apache-2.0Data structuresRust patterns genies_auth整合DDD与Dapr 的 auth 库200MIT/Apache-2.0ConfigurationRust patterns try-cloneFallible cloning.199MITRust patterns scoped-errorStructured error handling with semantic context trees.199Apache-2.0 WITH LLVM-exceptionCommand-line interfaceRust patterns kenzu-macroProcedural macros for builder pattern generation and validation196MIT OR Apache-2.0Development toolsRust patterns reliakit-retrySmall, runtime-agnostic retry helpers for fallible operations. Sync and async, never sleeps internally, no_std-friendly,…192MITAsynchronousNo standard library qubit-local-filesLocal filesystem utilities for Rust191Apache-2.0FilesystemRust patterns platifyStreamline cross-platform Rust development with declarative attribute macros.191MITDevelopment toolsOperating systems error-combinatorType-driven error composition with functional combinators191MITRust patterns reliakit-healthHealth status types and a criticality-aware aggregator for service health checks, probes, and status pages. no_std-friendly and…191MITData structuresNo standard library elicit_dbDatabase contract interface — Props, traits, and typestate for SQL domain boundaries189Apache-2.0 OR MITDatabase interfacesRust patterns atomr-diDependency-injection container for atomr.189Apache-2.0ConcurrencyRust patterns phlow-buildBuild-script support for generating phlow annotation metadata189MITDevelopment toolsRust patterns pilatusModular, extendable application framework for deterministic simulation of autonomous subsystems188MPL-2.0AsynchronousRust patterns terniTernary error handling: Success, Partial with measured loss, Failure. Because computation is not binary.188Apache-2.0No standard libraryRust patterns borrowizeDerive borrowed view structs from owned Rust structs.188MIT OR Apache-2.0Development toolsRust patterns fluxo-typestate-macrosZero-cost type-state pattern via procedural macros187MITDevelopment toolsRust patterns syanSyntactic and structural parser fundamentals, reimplementing syn crate186MITData structuresNo standard library::No dynamic allocation philiprehberger-result-extExtension traits for Result and Option with tap, map, and error accumulation186MITNo standard library::No dynamic allocationRust patterns field-kindsDerive macro for compile-time struct field type introspection185MITDevelopment tools::Procedural macro helpersRust patterns handle-this-macrosProc macros for handle-this error handling crate185MIT OR Apache-2.0Rust patterns str_enumSimple declarative macro for an enum with associated strings for each variant184MIT OR Apache-2.0Rust patterns trisultAn accumulating alternative to standard `Result<T, E>`.183MIT OR Apache-2.0No standard libraryNo standard library::No dynamic allocation to_segmentsErgonomic string splitting with readable methods for common manipulation tasks — cleaner alternative to .split().collect() chains180MITRust patternsText processing defaulted_deriveDerive macro for the IsDefault trait from the defaulted crate180MITDevelopment tools::Procedural macro helpersRust patterns pyenumExpose Rust enums to Python as real enum.Enum subclasses via PyO3.179MITAPI bindingsRust patterns migratexAgnostic migration toolkit library.176MITData structuresDatabase interfaces formatter-builderThe safe and stable builder for fmt::Formatter176MITNo standard libraryNo standard library::No dynamic allocation cirious_codex_resultRobust result and error handling framework for the Cirious Codex ecosystem.176MIT OR Apache-2.0Development tools::DebuggingRust patterns only_oneProvides the OnlyOne trait, which allows less nesting when chaining results176MIT OR Apache-2.0No standard libraryNo standard library::No dynamic allocation trisult-macrosA procedural macro module for `trisult`.176MIT OR Apache-2.0No standard libraryNo standard library::No dynamic allocation slice-of-bytes-readerTurns an iterator of `AsRef<[u8]>` into a reader implements `std::io::Read`175MITRust patterns parametric_deriveA derive macro to bridge complex, hierarchical data structures with optimization algorithms that use flat parameter vectors.174MIT OR Apache-2.0Development tools::Procedural macro helpersMathematics floopA more convenient and less error prone replacement for loop `{ select! { .. }}`173MIT OR Apache-2.0AsynchronousConcurrency neuer-errorErgonomic error handling for machines and humans.173MITNo standard libraryRust patterns trameFormally verified partial value construction for facet172MIT OR Apache-2.0Development toolsRust patterns result-aat-macrosThe Infomation and Result Trace crate172Apache-2.0Development tools::DebuggingNo standard library chaos_theory_deriveDerive macro for chaos_theory::Arbitrary172MPL-2.0Development tools::TestingRust patterns anyhowedAnyhow but with red 'error:' in terminal171MITDevelopment toolsRust patterns branded-idProvides data structures which can be branded such that they only work with similarly branded integer data types.170non-standardData structuresRust patterns reliakitReliability building blocks for Rust: validated primitives, secrets, bounded collections, backoff, retry helpers, circuit…168MITDevelopment toolsNo standard library use-checkComposable pass-fail check primitives for RustUse167MIT OR Apache-2.0Data structuresRust patterns commonsensePersonal ritual library of ergonomic Rust utilities167MIT OR Apache-2.0Development toolsRust patterns karpal-stdStandard prelude re-exports for the Karpal ecosystem167Apache-2.0No standard libraryRust patterns mce-procMarkdown Code Extractor procedural macros (part of mce): Collect code blocks from your README.md (or another Markdown file).…166BSD-2-Clause OR Apache-2.0 OR MITDevelopment toolsDevelopment tools::Testing sigma-enum-macrosProcedural macros for `sigma_enum`.166MIT/Apache-2.0Data structuresRust patterns reliakit-timeoutClock-agnostic deadlines and timeouts for retries and resilience. no_std and zero-dependency.166MITAlgorithmsNo standard library moxy-derivederive macros for moxy crate164MITDevelopment tools::Procedural macro helpersNo standard library newtype-ids-deriveDerive macros for the newtype-ids crate163MITRust patterns hexeract-macrosProcedural macros for the Hexeract messaging framework163MIT OR Apache-2.0AsynchronousRust patterns kael_derive_refineableA derive macro for creating refinement types in Rust for Kael158Apache-2.0Development tools::Procedural macro helpersRust patterns pyo3-gatedAttribute macros to expose Rust types to Python via PyO3 from a single definition - no duplicate structs or impl blocks.158MITAPI bindingsDevelopment tools::Procedural macro helpers cast-specExperimental: Compile-time architectural annotations for Rust — function-shaped macros that name concepts, rules, anti-patterns,…157MITDevelopment toolsRust patterns osmic-appPlugin system, App builder, event bus, and lifecycle157MITRust patternsScience::Geospatial oxide-mvuA standalone MVU runtime for Rust with no_std support for embedded systems156Apache-2.0Embedded developmentNo standard library enum-group-macros-implProcedural macros for enum grouping - companion crate for enum-group-macros155MITDevelopment tools::Procedural macro helpersRust patterns soupaProvides a macro allowing expressions to be eagerly evaluated before a scope.154MIT OR Apache-2.0No standard libraryNo standard library::No dynamic allocation skerry_macrosProc macros for skerry.153MITDevelopment toolsRust patterns eventide-macrosProcedural macros for the eventide DDD/CQRS toolkit: derive entities, entity ids, value objects and domain events with a single…153MIT OR Apache-2.0AsynchronousData structures rust-dixrust-dix: A Rust dependency injection framework inspired by Microsoft.Extensions.DependencyInjection152MITAsynchronousRust patterns fieldwork-macroProc-macro implementation for fieldwork crate152MITDevelopment toolsRust patterns