(git HEAD) std.datetime spewing deprecation messages

Steven Schveighoffer via Digitalmars-d digitalmars-d at puremagic.com
Thu Jun 5 15:18:33 PDT 2014


On Thu, 05 Jun 2014 18:06:01 -0400, monarch_dodra <monarchdodra at gmail.com>  
wrote:

> On Thursday, 5 June 2014 at 08:49:18 UTC, Jonathan M Davis via  
> Digitalmars-d
>>     long days;
>>     int seconds;
>>     short msecs;
>>     d.split!("days", "seconds", "msecs")(&days, &seconds, &msecs);
>
> Please don't use pass-by-pointer in D APIs. It makes it a real  
> *nightmare* to ever use the code in a safe context.

This is similar to getopt and readf. I think it's a good way to show that  
a reference is being passed.

But you are right, you are not allowed to take addresses of locals in safe  
code. It looks decidedly less nice than pointers IMO.

-Steve


More information about the Digitalmars-d mailing list