NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
crates.io · #4472 most downloaded on crates.io
Generate enums with same variants, but without data.
Last release 1 months ago
31 Aug 2026
Release timing varies
gaps range from 3 months to 2.2 years
Nearly every release is documented
notes for 9 of 10 stable releases
Nothing withdrawn
no release was ever pulled
3 years old
10 releases · first in 2023
One column per quarter.
Add const fn as_str() method to the kind type, returning the variant name as &'static str. The value respects the display and rename attributes, so it
const fn as_str() method to the kind type, returning the variant name as &'static str.
The value respects the display and rename attributes, so it always matches the Display output.Kinded is a Rust procedural macro that generates a companion "kind" enum with the same variants as your original enum but without the associated data.
Kinded is a Rust procedural macro that generates a companion "kind" enum with the same variants as your original enum but without the associated data.
skip_derive attributeOpt out of default trait implementations when you need custom behavior or want to avoid conflicts with other derives.
use kinded::Kinded;
#[derive(Kinded)]
#[kinded(skip_derive(Display, FromStr))]
enum Status {
Active,
Inactive,
}
// Now you can implement Display and FromStr manuallyAvailable traits to skip: Display, FromStr, From, Clone, Copy, Debug, PartialEq, Eq.
attrs attribute for generated enumPass extra attributes to the generated kind enum, useful for integrating with serde and other derive macros.
use kinded::Kinded;
use serde::{Serialize, Deserialize};
#[derive(Kinded)]
#[kinded(attrs(derive(Serialize, Deserialize), serde(rename_all = "snake_case")))]
enum Beverage {
Coffee(String),
Tea { flavor: String },
Water,
}
// BeverageKind now has Serialize/Deserialize with snake_case namingattrs attributeApply attributes to individual kind variants for fine-grained control.
use kinded::Kinded;
use serde::{Serialize, Deserialize};
#[derive(Kinded)]
#[kinded(attrs(derive(Serialize, Deserialize)))]
enum Priority {
#[kinded(attrs(serde(rename = "p0")))]
Critical,
#[kinded(attrs(serde(rename = "p1")))]
High,
Normal,
Low,
}const fn kind() methodThe kind() method is now const fn, enabling use in const contexts.
use kinded::Kinded;
#[derive(Kinded)]
enum Direction {
North,
South,
East,
West,
}
const NORTH_KIND: DirectionKind = Direction::North.kind();
const fn is_vertical(dir: &Direction) -> bool {
matches!(dir.kind(), DirectionKind::North | DirectionKind::South)
}Update your Cargo.toml:
[dependencies]
kinded = "0.5"skip_derive attribute to opt out of default trait implementations (fixes #19).attrs attribute to pass extra attributes to the generated kind enum (e.g., #[kinded(attrs(serde(rename_all = "snake_case")))])attrs attribute to pass attributes to individual kind variants (e.g., #[kinded(attrs(default))]) (fixes #22)kind() method const fn, allowing usage in const contexts (fixes #12)Add #[kinded(rename = "...")] attribute for variants to customize display/parse names. This is useful when the automatic case conversion doesn't produ
#[kinded(rename = "...")] attribute for variants to customize display/parse names.
This is useful when the automatic case conversion doesn't produce the desired result.- Update to Rust 2024 edition. - no_std support.
[BREAKING] - Make ::all() function return an array instead of vector.
::all() function return an array instead of vector.Changes Add Kind trait.
Add ::all() to the kind type to iterate over all kind variants
::all() to the kind type to iterate over all kind variantsDisplay traitFromStr traitNothing published for this version
Make the generated kind() function public
kind() function publicChanges Support enums with generics
Your coding agent can read these notes before it upgrades. Set up the MCP server →