www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 11429] New: Deprecate walkLength?

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

           Summary: Deprecate walkLength?
           Product: D
           Version: D2
          Platform: x86
        OS/Version: Windows
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Phobos
        AssignedTo: nobody puremagic.com
        ReportedBy: bearophile_hugs eml.cc


--- Comment #0 from bearophile_hugs eml.cc 2013-11-03 06:39:25 PST ---
This is an alternative to issue 8467.

If issue 8467 is refused, then I suggest to just deprecate walkLength, and
leave only count(), because it can replace walkLength (if count lacks the
".length" shortcut optimization, it should be added):


import std.algorithm: count, map;
void main() {
    assert([0, 0, 1].map!(x => x).count == 3);
}

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