| commit | 9f59d1aabc1d93bfe216e0af924d1fa642bc672e | [log] [tgz] |
|---|---|---|
| author | Jeff Vander Stoep <jeffv@google.com> | Thu Nov 05 15:27:50 2020 +0100 |
| committer | Jeff Vander Stoep <jeffv@google.com> | Thu Nov 05 15:27:50 2020 +0100 |
| tree | f865d7a89806ca82f268b07460e74266336bf724 | |
| parent | f027af41df70f031162a288c395846352e5cfc8a [diff] |
TEST_MAPPING: test dependers of this crate Bug: 168167373 Test: TH Change-Id: Ib22690d151f3042ee01efea1243f55454de03771
Pre-allocated storage for a uniform data type.
To use slab, first add this to your Cargo.toml:
[dependencies] slab = "0.4.2"
Next, add this to your crate:
extern crate slab; use slab::Slab; let mut slab = Slab::new(); let hello = slab.insert("hello"); let world = slab.insert("world"); assert_eq!(slab[hello], "hello"); assert_eq!(slab[world], "world"); slab[world] = "earth"; assert_eq!(slab[world], "earth");
See documentation for more details.
This project is licensed under the MIT license.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in slab by you, shall be licensed as MIT, without any additional terms or conditions.