EnuMap
HashMap and HashSet like interfaces for enumerations backed by an array.
enumap
is no_std
compatible, dependency and proc macro free for blazingly fast compilation speeds.
Usage
This crate is on crates.io and can be
used by adding it to your dependencies in your project's Cargo.toml
.
[]
= "0.3"
Examples
use ;
enumap!
// A fruit shop: fruit -> stock.
let mut shop = new;
let mut orders = new;
shop.insert;
shop.insert;
for in &shop
if !shop.contains_key
for fruit in &orders
Browse the docs for more examples!