[Issue 4347] foreach over range should save range.

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Thu Jun 12 13:02:18 PDT 2014


https://issues.dlang.org/show_bug.cgi?id=4347

monarchdodra at gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |monarchdodra at gmail.com

--- Comment #2 from monarchdodra at gmail.com ---
I disagree with this. saving a range should always be the caller's
responsibility/choice.

If the argument "people expect the range to be saved" prevails here, it means
"save" is failed as a concept, and forward ranges should simply be defined as
"ranges that implicitly save on copy": EG no need for save, only for a postblit
that's *always* called.

--


More information about the Digitalmars-d-bugs mailing list