array

A sink that reads the entire stream and stores its contents in a GC-allocated array.

array cannot be used for pipelines that start with an output range wrapper (flod.range.pass(E)). If you need a pipeline with output range interface that stores the output in an array, use flod.range.pass with delegate parameter or flod.range.copy with std.array.Appender.

array
(
S
)
()

Return Value

Type: auto

A GC-allocated array filled with the output of the previous stage.

Examples

import std.range : iota, stdarray = array;
assert(iota(1048576).array == iota(1048576).stdarray);

See Also

flod.range.copy

Meta