On Fri, 06 Jun 2014 03:30:19 +0200
Artur Skawina via Digitalmars-d <[email protected]> wrote:

> On 06/06/14 02:34, Jonathan M Davis via Digitalmars-d wrote:
> And you get an API which looks like this:
>
>    auto r = d.split!q{ days, seconds, msecs };
>    // access r.days etc

You can already do that with what I have in my current pull except that it's

    auto r = d.split!("days", "seconds", "msecs")();
    auto days = r.days;
    auto seconds = r.seconds;
    auto msecs = r.msecs;

It's up to you whether you want to pass in pointers or return a struct. Which
is better tends to depend on the context in which the function is used.

- Jonathan M Davis

Reply via email to