[Issue 4492] Version of take() which takes from the back of a range
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Thu Jul 22 07:50:55 PDT 2010
http://d.puremagic.com/issues/show_bug.cgi?id=4492
Steven Schveighoffer <schveiguy at yahoo.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |schveiguy at yahoo.com
--- Comment #5 from Steven Schveighoffer <schveiguy at yahoo.com> 2010-07-22 07:50:51 PDT ---
(In reply to comment #2)
> You get the elements in the wrong order. Now, you could do
>
> retro(take(retro(myRange), someNumber))
That won't work, retro needs a bidirectional range, and take is not a
bidirectional range.
Like David said, your takeBack will only work on random access ranges, an O(n)
cost for constructing a range is unacceptable.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list