[Request] A way to extract all instance of X from a range

Marc Schütz via Digitalmars-d digitalmars-d at puremagic.com
Wed Mar 23 06:27:16 PDT 2016


On Wednesday, 23 March 2016 at 11:36:39 UTC, Nick Treleaven wrote:
> On Tuesday, 22 March 2016 at 20:09:51 UTC, Matthias Bentrup 
> wrote:
>> It is logically just a combination of map and concat (which 
>> turns a range of ranges into a combined range, but I think 
>> that one is missing in the std lib too).
>
> http://dlang.org/phobos/std_range.html#.chain

Or joiner(), if you have a range of ranges:
http://dlang.org/phobos/std_algorithm_iteration.html#.joiner


More information about the Digitalmars-d mailing list