http://d.puremagic.com/issues/show_bug.cgi?id=6652



--- Comment #12 from bearophile_h...@eml.cc 2012-06-16 05:07:21 PDT ---
(In reply to comment #10)

> They are the phases to change behavior.

I see.


> I think we should allow modifying loop
> variable in foreach body, but it should not affect to iteration.

Generally changing the iteration variable isnt't a very good idea. It looks
bug-prone, like modifying function arguments inside functions :-)

foreach (i; 0 .. 10) { i++; writeln(i); }


> So there is no
> code that changes the foreach-on-range iteration variable.

Good.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to