The array of slices itself requires allocation.

Andrei

On 04/26/2010 05:15 PM, Ellery Newcomer wrote:
Andrei Alexandrescu<and...@...>  writes:



I suggest we go with lazy ranges throughout. No memory allocation unless
the user asks for it by calling std.array.array(range).  For example,
splitter() vs. split() was a huge accelerator in virtually all my text
processing programs.

Andrei


Fine by me as long as it gets in.

Iḿ a bit curious, though. path2list currently returns an array of slices into
the original path. I have a hard time imagining memory allocation this way would
be much higher than as a range (unless the original path is also a lazy range).

Next week finals will be over. Iĺl rewrite the bugger then.


_______________________________________________
phobos mailing list
[email protected]
http://lists.puremagic.com/mailman/listinfo/phobos
_______________________________________________
phobos mailing list
[email protected]
http://lists.puremagic.com/mailman/listinfo/phobos

Reply via email to