nomvec

Crates.ionomvec
lib.rsnomvec
version0.1.1
sourcesrc
created_at2020-07-16 19:58:19.244705
updated_at2020-07-16 19:58:19.244705
descriptionVector implementation from
homepage
repository
max_upload_size
id265943
size13,657
Clifton King (clifton)

documentation

README

rust-nomvec

vector implementation from The Rustonomicon thats compatible with rust stable 1.45

Testing

$ cargo test

Using

use nomvec::NomVec;

let mut cv: NomVec<i32> = NomVec::new();
cv.insert(0, 1);
cv.insert(0, 0);
cv.push(2);
for (i, x) in cv.iter().enumerate() {
    assert_eq!(i as i32, *x);
}
assert_eq!(cv.remove(0), 0);
assert_eq!(cv.len(), 2);
Commit count: 0

cargo fmt