commit | daac80773084089e7f758dd5f3f3572bbf5566db | [log] [tgz] |
---|---|---|
author | Matthew Maurer <mmaurer@google.com> | Thu May 26 12:27:30 2022 -0700 |
committer | Matthew Maurer <mmaurer@google.com> | Thu May 26 12:27:30 2022 -0700 |
tree | 90a3e3a6412fff3804630f7ddbccabdf806fb3b9 | |
parent | b54de970eb3a80b64222362b7e35e8d0ecde7848 [diff] |
Update TEST_MAPPING Test: None Bug: 233924440 Change-Id: I7b4d4be39f2210836236b319ef53dd2a6b662ea0
Pre-allocated storage for a uniform data type.
To use slab
, first add this to your Cargo.toml
:
[dependencies] slab = "0.4"
Next, add this to your crate:
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.