ni 0.2.7

Small limited alloc-free named identifier
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use {
    ni::Name,
    std::{collections::HashMap, fs, io},
};

fn main() -> io::Result<()> {
    let content = fs::read_to_string("examples/data.json")?;

    // If you get the error "the trait bound `Name: serde::Deserialize<'_>`
    // is not satisfied", enable the `serde` feature
    let data: HashMap<Name, u32> = serde_json::from_str(&content)?;
    println!("{data:#?}");

    Ok(())
}