[Issue 10009] foreach_reverse and AA.byKey/byValue
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Fri Sep 26 01:55:09 PDT 2014
https://issues.dlang.org/show_bug.cgi?id=10009
--- Comment #24 from bearophile_hugs at eml.cc ---
(In reply to Ketmar Dark from comment #21)
> it's wrong to assume that AA has any defined order of items for
> iteration.
It's not wrong, it's a handy feature, just as in Python the default sort is
stable. Ordered dict is handy for unittesting and in other situations. And it's
handy to use built-in data structures in unittesting.
> why include language feature that is known to
> be slow when it can be reasonably fast?
Tracking the insertion order is not that slow...
--
More information about the Digitalmars-d-bugs
mailing list