Implemented nextIteration and escapeWhile.