Skip to content

IteratorQuery.Contracts

Define core iterator contracts used by the IteratorQuery feature, including pipelines and for in lowering.

pub contract Iterator<T> {
Option<T> Next();
}
  • for item in expr consumes iterator-capable values through Next().
  • Contract remains backend-neutral and monomorphization-friendly.