[][src]Macro literally::hmap

macro_rules! hmap {
    (@single $($x:tt)*) => { ... };
    (@count $($rest:expr),*) => { ... };
    ($($key:expr => $value:expr),* $(,)?) => { ... };
}

Literally just a HashMap literal with keys and values into'd.

let m: HashMap<String, String> = hmap!{ "key" => "value" };
assert_eq!(m.get("key"), Some(&"value".to_string()))