#data #map #default #compact

dpc-simplemap

Simple map with default value and compacting

4 releases

Uses old Rust 2015

0.1.0 Mar 23, 2016
0.0.3 Dec 4, 2015
0.0.2 Aug 2, 2015
0.0.1 Jun 23, 2015

#6 in #compact

Download history 3/week @ 2021-08-07 5/week @ 2021-08-14 2/week @ 2021-08-21 2/week @ 2021-08-28 1/week @ 2021-09-04 4/week @ 2021-09-11 4/week @ 2021-09-18 4/week @ 2021-09-25 2/week @ 2021-10-02 7/week @ 2021-10-09 1/week @ 2021-10-16 2/week @ 2021-10-23 4/week @ 2021-10-30 6/week @ 2021-11-06 4/week @ 2021-11-13 5/week @ 2021-11-20

208 downloads per month

MPL-2.0 license

13KB
323 lines

simplemap

Build Status crates.io Gitter Chat
Documentation

Introduction

Simple Map with default for missing values and compacting (removal of default values from underlying map).

Usage

Simplemap version 0.0.2 compiles only with Rust nightly. If you want stable-compatibility use no_hash_state branch.

In Carto.toml

[dependencies]
dpc-simplemap = "*"

In src/main.rs:

extern crate simplemap;

lib.rs:

Simple Map with default for missing values and compacting (removal of elements with default value from underlying map).

So you can just:

use simplemap::SimpleMap;

let mut map = SimpleMap::new();

assert_eq!(map[0u32], 0u32);
map[1] = 3;
assert_eq!(map[1], 3);

Dependencies

~18KB

7V