commit | 0f89d9a5d0b36ce061096d6d49443fb93dc50485 | [log] [tgz] |
---|---|---|
author | Julien Desprez <jdesprez@google.com> | Wed Feb 10 05:33:21 2021 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Wed Feb 10 05:33:21 2021 +0000 |
tree | 83c3251e08034ef429da66dd7a5da24ccc00b43e | |
parent | a642f4148411e1e5e2eea2fbbfaeb9f29eea6f3a [diff] | |
parent | 161a04beb9ecf2a6e448e6b42a61b375f63867bd [diff] |
Clean up rust_test_host TEST_MAPPING after default update am: 202f2eb278 am: 527b6f9e33 am: 161a04beb9 Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/slab/+/1582764 MUST ONLY BE SUBMITTED BY AUTOMERGER Change-Id: I2a7b5c08755a549e4f33221a6aef85e48a9e8442
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.