[phobos] phobos commit, revision 2237

dsource.org noreply at dsource.org
Mon Dec 27 11:02:46 PST 2010


phobos commit, revision 2237


user: schveiguy

msg:
Fixed std.array.Appender so it uses the newcapacity function to determine grow size when appending a range.  Previously, it just grew enough to fit the range contents, which does not amortize appending performance.

Now, appending a range beats builtin append.  I noticed that appending a range does not beat appending single elements when the size of the range is small (such as one element).  There are probably heuristics we can find to optimize the copying, but I have a feeling these should just go into the builtin array copy code anyways.

Fixes bugzilla 5198

http://www.dsource.org/projects/phobos/changeset/2237

paths changed:
U   trunk/phobos/std/array.d



More information about the phobos mailing list