pub fn chunks_exact_mut(
		&mut self,
		chunk_size: usize,
	) -> ChunksExactMut<T, O> {
		ChunksExactMut::new(self, chunk_size)
	}
/// Iterates over non-overlapping mutable subslices of a bit-slice.
///
/// If `self.len()` is not an even multiple of `chunk_size`, then the last
/// few bits are not yielded by the iterator at all. They can be accessed
/// with the [`.into_remainder()`] method if the iterator is bound to a
/// name.
///
/// Iterators do not require that each yielded item is destroyed before the
/// next is produced. This means that each bit-slice yielded must be marked
/// as aliased. If you are using this in a loop that does not collect
/// multiple yielded subslices for the same scope, then you can remove the
/// alias marking by calling the (`unsafe`) method [`.remove_alias()`] on
/// the iterator.
///
/// ## Original
///
/// [`slice::chunks_exact_mut`](https://doc.rust-lang.org/std/primitive.slice.html#method.chunks_exact_mut)
///
/// ## Sibling Methods
///
/// - [`.chunks_mut()`] yields any leftover bits at the end as a shorter
///   chunk during iteration.
/// - [`.chunks_exact()`] has the same division logic, but each yielded
///   bit-slice is immutable.
/// - [`.rchunks_exact_mut()`] iterates from the back of the bit-slice
///   forwards, with the unyielded remainder segment at the front edge.
///
/// ## Panics
///
/// This panics if `chunk_size` is `0`.
///
/// ## Examples
///
/// ```rust
/// use bitvec::prelude::*;
///
/// let bits = bits![mut u8, Msb0; 0; 5];
/// let mut iter = bits.chunks_exact_mut(2);
///
/// for (idx, chunk) in iter.by_ref().enumerate() {
///   chunk.store(idx + 1);
/// }
/// iter.into_remainder().store(1u8);
///
/// assert_eq!(bits, bits![0, 1, 1, 0, 1]);
/// //                       remainder ^
/// ```
///
/// [`.chunks_exact()`]: Self::chunks_exact
/// [`.chunks_mut()`]: Self::chunks_mut
/// [`.into_remainder()`]: crate::slice::ChunksExactMut::into_remainder
/// [`.rchunks_exact_mut()`]: Self::rchunks_exact_mut
/// [`.remove_alias()`]: crate::slice::ChunksExactMut::remove_alias
Iterates over non-overlapping mutable subslices of a bit-slice.
If `self.len()` is not an even multiple of `chunk_size`, then the last
few bits are not yielded by the iterator at all. They can be accessed
with the [`.into_remainder()`] method if the iterator is bound to a
name.

Iterators do not require that each yielded item is destroyed before the
next is produced. This means that each bit-slice yielded must be marked
as aliased. If you are using this in a loop that does not collect
multiple yielded subslices for the same scope, then you can remove the
alias marking by calling the (`unsafe`) method [`.remove_alias()`] on
the iterator.
Iterates over non - overlapping mutable subslices of a bit - slice . If ` self . len () ` is not an even multiple of ` chunk_size ` then the last few bits are not yielded by the iterator at all . They can be accessed with the [ ` . into_remainder () ` ] method if the iterator is bound to a name . Iterators do not require that each yielded item is destroyed before the next is produced . This means that each bit - slice yielded must be marked as aliased . If you are using this in a loop that does not collect multiple yielded subslices for the same scope then you can remove the alias marking by calling the ( ` unsafe ` ) method [ ` . remove_alias () ` ] on the iterator .
pub fn chunks_exact_mut(
		&mut self,
		chunk_size: usize,
	) -> ChunksExactMut<T, O> {
		ChunksExactMut::new(self, chunk_size)
	}
pub fn chunks_exact_mut ( & mut self , chunk_size : usize , ) -> ChunksExactMut < T , O > { ChunksExactMut :: new ( self , chunk_size ) }
Iterates over non-overlapping mutable subslices of a bit-slice.
Iterates over non - overlapping mutable subslices of a bit - slice .
&mut self
chunk_size
usize
&mut self
chunk_size
usize
original
None
sibling methods
[`.chunks_mut()`] yields any leftover bits at the end as a shorter
chunk during iteration.
[`.chunks_exact()`] has the same division logic, but each yielded
bit-slice is immutable.
[`.rchunks_exact_mut()`] iterates from the back of the bit-slice
forwards, with the unyielded remainder segment at the front edge.
[ ` . chunks_mut () ` ] yields any leftover bits at the end as a shorter chunk during iteration . [ ` . chunks_exact () ` ] has the same division logic but each yielded bit - slice is immutable . [ ` . rchunks_exact_mut () ` ] iterates from the back of the bit - slice forwards with the unyielded remainder segment at the front edge .
panics
This panics if `chunk_size` is `0`.
This panics if ` chunk_size ` is ` 0 ` .
examples
```rust
use bitvec::prelude::*.

let bits = bits![mut u8, Msb0; 0; 5];
let mut iter = bits.chunks_exact_mut(2).

for (idx, chunk) in iter.by_ref().enumerate() {
chunk.store(idx + 1);
}
iter.into_remainder().store(1u8).




` ` ` rust use bitvec :: prelude :: * . let bits = bits! [ mut u8 Msb0 ; 0 ; 5 ] ; let mut iter = bits . chunks_exact_mut ( 2 ) . for ( idx chunk ) in iter . by_ref () . enumerate () { chunk . store ( idx + 1 ) ; } iter . into_remainder () . store ( 1u8 ) .