fn next_el_gen(&mut self) -> Option<(Cow<'_, T>, &T)> {
        if self.queue.is_empty() {
            return None;
        }

        let el;
        let gen = &self.gens[self.gen_idx];

        // Advances the indices.
        self.gen_idx += 1;
        if self.gen_idx == self.gens.len() {
            self.gen_idx = 0;
            el = Cow::Owned(self.queue.front().unwrap().clone());
            self.queue.pop_front();
        } else {
            el = Cow::Borrowed(self.queue.front().unwrap());
        }

        Some((el, gen))
    }
/// Gets the next element and the next generator to attempt to multiply
/// with. Advances the iterator.
Gets the next element and the next generator to attempt to multiply
with. Advances the iterator.
Gets the next element and the next generator to attempt to multiply with . Advances the iterator .
fn next_el_gen(&mut self) -> Option<(Cow<'_, T>, &T)> {
        if self.queue.is_empty() {
            return None;
        }
        let el;
        let gen = &self.gens[self.gen_idx];
        // Advances the indices.
        self.gen_idx += 1;
        if self.gen_idx == self.gens.len() {
            self.gen_idx = 0;
            el = Cow::Owned(self.queue.front().unwrap().clone());
            self.queue.pop_front();
        } else {
            el = Cow::Borrowed(self.queue.front().unwrap());
        }
        Some((el, gen))
    }
fn next_el_gen ( & mut self ) -> Option < ( Cow < ' _ , T > , & T ) > { if self . queue . is_empty ( ) { return None ; } let el ; let gen = & self . gens [ self . gen_idx ] ; // Advances the indices. self . gen_idx += 1 ; if self . gen_idx == self . gens . len ( ) { self . gen_idx = 0 ; el = Cow :: Owned ( self . queue . front ( ) . unwrap ( ) . clone ( ) ) ; self . queue . pop_front ( ) ; } else { el = Cow :: Borrowed ( self . queue . front ( ) . unwrap ( ) ) ; } Some ( ( el , gen ) ) }
Gets the next element and the next generator to attempt to multiply
with.
Gets the next element and the next generator to attempt to multiply with .
&mut self
&mut self