Re-exported from core::iter::Pair.
forall A, B.
exposed struct Pair {
a: A,
b: B,
}
A named pair: the item type of zip and enumerate.
Instances
instance Iterator[Zip[IA, IB] -> Pair[ItemA, ItemB]]source
forall IA, IB, ItemA, ItemB where Iterator[IA -> ItemA], Iterator[IB -> ItemB], Copy[ItemA], Copy[ItemB].
instance Iterator[Zip[IA, IB] -> Pair[ItemA, ItemB]] { ... }
In std::iter.
zip: the next item of each, paired, until either runs out.
instance Iterator[Enumerate[I] -> Pair[usize, T]]source
forall I, T where Iterator[I -> T].
instance Iterator[Enumerate[I] -> Pair[usize, T]] { ... }
In std::iter.
enumerate: the next item with its index.
instance Iterator[Drain![K, V, 'k] -> Pair[K, V]]source
forall K, V, 'k where Sized[K], Sized[V].
instance Iterator[Drain![K, V, 'k] -> Pair[K, V]] { ... }
The drained entries, each moved out as Pair { a: key, b: value }.