How do I convert an ISO 8601 datetime into a unix timestamp - at compile-time?
Andrej Mitrovic
andrej.mitrovich at gmail.com
Mon Aug 31 04:55:56 UTC 2020
On Friday, 28 August 2020 at 12:35:26 UTC, Steven Schveighoffer
wrote:
> It's trying to look up the local timezone at compile time.
>
> You need to specify a time zone:
>
> static time =
> SysTime(DateTime.fromISOString("20220101T000000"),
> UTC()).toUnixTime;
>
> -Steve
Aw, thanks Steve!
More information about the Digitalmars-d-learn
mailing list