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

#622 in Data structures

Download history 107936/week @ 2025-10-26 109239/week @ 2025-11-02 97211/week @ 2025-11-09 114045/week @ 2025-11-16 104149/week @ 2025-11-23 115602/week @ 2025-11-30 108843/week @ 2025-12-07 119102/week @ 2025-12-14 66013/week @ 2025-12-21 50457/week @ 2025-12-28 116567/week @ 2026-01-04 127311/week @ 2026-01-11 126332/week @ 2026-01-18 120507/week @ 2026-01-25 137579/week @ 2026-02-01 124856/week @ 2026-02-08

517,043 downloads per month
Used in 2,791 crates (86 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

~160KB