Passing ranges around
Mike Parker via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Tue Jul 12 01:32:51 PDT 2016
On Tuesday, 12 July 2016 at 07:50:34 UTC, Bahman Movaqar wrote:
> On 07/12/2016 11:07 AM, Mike Parker wrote:
>> auto foo(R)(R r) { ... }
>
> That did it. Thanks.
> Out of curiosity, does the same pattern apply to functions
> which take
> `tuple`s as input arguments?
It's just a function template. It's what you use whenever you
need to deal with generic types.
https://dlang.org/spec/template.html
More information about the Digitalmars-d-learn
mailing list