This test program fails:
import aria.range.int_extension;
val inner = 0;
val outer = 0;
for i in 0.to(12) {
for i in 0.to(500) {
inner += 1;
}
outer += 1;
}
assert inner == 6000;
assert outer == 12;
because it only goes through the outer loop once, it sees i == 500 at the end of the first iteration and gets out
The program behaves correctly if embedded in a func main()
This test program fails:
because it only goes through the outer loop once, it sees
i == 500at the end of the first iteration and gets outThe program behaves correctly if embedded in a
func main()