[phobos] std.path proof of concept

Andrei Alexandrescu andrei at erdani.com
Mon Apr 26 15:16:57 PDT 2010


The array of slices itself requires allocation.

Andrei

On 04/26/2010 05:15 PM, Ellery Newcomer wrote:
> Andrei Alexandrescu<andrei at ...>  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
> phobos at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/phobos


More information about the phobos mailing list