Crates.io | indexvec |
lib.rs | indexvec |
version | 0.5.4 |
source | src |
created_at | 2021-11-03 22:42:12.516425 |
updated_at | 2022-03-19 04:32:19.142562 |
description | Simplified copy of rustc's index crate |
homepage | |
repository | https://github.com/andyyu2004/indexvec |
max_upload_size | |
id | 476368 |
size | 10,833 |
A simplified copy of rustc's index crate.
newtype_index! {
pub struct MyIndex;
}
// Shorthand for the above
newtype_index!(pub MyIndex);
// Full example of all features
newtype_index! {
#[derive(SomeTrait)]
pub struct MyIndex {
pub const A = 5;
pub const B = 999;
}
}
Serde can be enabled with the serde
feature.