How convert DList!string to string array

Denis Mezhov d.o.mezhov at gmail.com
Sat Feb 15 08:52:11 PST 2014


On Saturday, 15 February 2014 at 16:38:42 UTC, Timon Gehr wrote:
> On 02/15/2014 05:30 PM, Denis Mezhov wrote:
>> Please help. How to convert DList!string to string array?
>>
>> auto a = DList!string();
>> a.insertFront("123");
>> a.insertFront("abc");
>>
>> string[] b = a[];
>> Array!string c = a[];
>>
>> Don't work.
>>
>>
>
> auto b = a[].array;
> Array!string c;
> c.insertBack(a[]);

It works! Thanks for the quick reply.


More information about the Digitalmars-d-learn mailing list