1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
//! `bitwise` offers portable high-level manipulation algorithms
//! ([@github](https://github.com/gnzlbg/bitwise),
//! [@crates.io](https://crates.io/crates/bitwise)).
//!
//! The algorithms:
//!
//! - have descriptive names to ease reading code that performs bit manipulations,
//! - often optimize to perfect assembly code (and _always_ on nightly by using
//! the [`bitintr`](https://crates.io/crates/bitintr) crate),
//! - works on ~~stable~~ unstable only :( due to specialization for now.
//!
//! ## Example
//!
//! ```rust
//! extern crate bitwise;
//! use bitwise::word::*;
//!
//! fn main() {
//! let u = outer_perfect_shuffle(0b_1001_1111u8);
//! let v = inner_perfect_shuffle(0b_1001_1111u8);
//! let w = u.copy_bit(4u8, v, 3u8);
//! assert_eq!(w.parallel_bits_deposit(u), 0b_1001_0011u8);
//! }
//! ```
extern crate core as std;
extern crate test;
/// Low-level bitwise manipulation intrinsics.
pub extern crate bitintr;
pub use *;