[Issue 1878] foreach does not handle integral types appropriately

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Apr 2 04:16:42 PDT 2014


https://d.puremagic.com/issues/show_bug.cgi?id=1878



--- Comment #6 from bearophile_hugs at eml.cc 2014-04-02 04:16:33 PDT ---
Currently this works:

ubyte whatever() { return 10; }
void main() {
    ubyte limit = whatever();
    ubyte x;
    foreach (ubyte e; 0 .. limit)
       x = e;
}

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


More information about the Digitalmars-d-bugs mailing list