31 releases

Uses old Rust 2015

0.11.1 Mar 19, 2020
0.11.0 Jan 16, 2019
0.10.0 Jun 20, 2018
0.4.2 Mar 31, 2018

#307 in Data structures

Download history 81853/week @ 2025-05-14 71760/week @ 2025-05-21 79107/week @ 2025-05-28 82846/week @ 2025-06-04 83676/week @ 2025-06-11 77030/week @ 2025-06-18 74426/week @ 2025-06-25 71192/week @ 2025-07-02 72733/week @ 2025-07-09 73300/week @ 2025-07-16 73480/week @ 2025-07-23 93320/week @ 2025-07-30 100505/week @ 2025-08-06 88218/week @ 2025-08-13 90850/week @ 2025-08-20 96604/week @ 2025-08-27

396,697 downloads per month
Used in 2,306 crates (72 directly)

MIT/Apache

165KB
3.5K SLoC

bv-rs: bit-vectors and bit-slices for Rust

Build Status Crates.io License: MIT License: Apache 2.0

The main type exported by the library, BitVec, is a packed, growable bit-vector. Its API mirrors that of Vec where reasonable. The library also defines slice operations that return BitSlice or BitSliceMut, akin to Rust’s array slices but for bit-vectors. A common API to bit-vectors and bit-slices is provided by the Bits, BitsMut, and BitsPush traits, which also allow treating as bit-vectors all primitive unsigned integer types (uN), and vectors and slices thereof, as well as unpacked vectors and slices of bool.

Usage

It’s on crates.io, so you can add

[dependencies]
bv = "0.11.1"

to your Cargo.toml and

extern crate bv;

to your crate root.

This crate supports Rust version 1.31 and newer.

Dependencies

~150KB