Function select_ones

Source
pub fn select_ones(
    index: &[u64],
    all_bits: BitsRef<'_>,
    target_rank: u64,
) -> Option<u64>
Expand description

Find the position of a set bit by its rank using the index (O(log n)).

Returns None if no suitable bit is found. It is always the case otherwise that rank_ones(index, result) == Some(target_rank) and get(result) == Some(true).