0.1.0-pre.3 |
|
---|
#24 in #declare
9KB
208 lines
Branded ID — bid
This library streamlines the process of defining and branded ID types through
the bid::declare!
macro.
Example:
bid::declare!(pub struct UserId(i32));
#[derive(Debug, Deserialize, Serialize)]
pub struct User {
pub id: UserId,
pub username: String,
// ...
}
Dependencies
~0.1–1.8MB
~34K SLoC