https://issues.dlang.org/show_bug.cgi?id=15413 --- Comment #2 from ZombineDev <petar.p.kirov at gmail.com> --- I meant: foreach (v; ir) { // user code } // =====v==== for ( ; !ir.empty; ir.popFront()) { auto v = ir.front; // user code } --