JH-Toolkit v1.4.1
An engineering-oriented C++20 toolkit with duck-typed concepts, static design, async coroutines, and semantic containers — header-only, RTTI-free, and concurrency-friendly.
Loading...
Searching...
No Matches
jh::runtime_arr< bool >::bit_const_iterator Struct Referencefinal

Const iterator over individual bits in the bit-packed array. More...

#include <jh/core/runtime_arr.h>

Public Types

using iterator_concept = std::random_access_iterator_tag
using iterator_category = iterator_concept
using value_type = bool
using difference_type = std::ptrdiff_t
using reference = bit_ref
using pointer = void

Public Member Functions

 bit_const_iterator (const runtime_arr *parent, const std::uint64_t index)
bool operator* () const
bit_const_iterator & operator++ ()
bit_const_iterator operator++ (int)
bit_const_iterator & operator-- ()
bit_const_iterator operator-- (int)
bit_const_iterator & operator+= (const difference_type n)
bit_const_iterator & operator-= (const difference_type n)
bit_const_iterator operator+ (const difference_type n) const
bit_const_iterator operator- (const difference_type n) const
difference_type operator- (const bit_const_iterator &other) const
bool operator== (const bit_const_iterator &other) const
bool operator!= (const bit_const_iterator &other) const
bool operator< (const bit_const_iterator &other) const
bool operator<= (const bit_const_iterator &other) const
bool operator> (const bit_const_iterator &other) const
bool operator>= (const bit_const_iterator &other) const

Public Attributes

const runtime_arrparent_
std::uint64_t index_

Detailed Description

Const iterator over individual bits in the bit-packed array.

Behaves similarly to bit_iterator but yields immutable boolean values directly instead of proxy references. Suitable for read-only traversal of the packed bit representation.

Note
As with bit_iterator, proxy characteristics prevent runtime_arr<bool> from modeling a fully valid std::ranges-compatible boolean range. For a true boolean range, prefer jh::runtime_arr<bool, jh::runtime_arr_helper::bool_flat_alloc>.

The documentation for this struct was generated from the following file: