Skip to content

Commit

Permalink
Solaris fixes for std.datetime
Browse files Browse the repository at this point in the history
  • Loading branch information
kinke committed Jan 4, 2018
1 parent 66bb891 commit 9f8482a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions std/datetime/timezone.d
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,7 @@ public:
else version(DragonFlyBSD) enum utcZone = "UTC";
else version(linux) enum utcZone = "UTC";
else version(OSX) enum utcZone = "UTC";
else version(Solaris) enum utcZone = "UTC";
else static assert(0, "The location of the UTC timezone file on this Posix platform must be set.");

auto tzs = [testTZ("America/Los_Angeles", "PST", "PDT", dur!"hours"(-8), dur!"hours"(1)),
Expand Down Expand Up @@ -2007,6 +2008,14 @@ public:
// Android concatenates all time zone data into a single file and stores it here.
enum defaultTZDatabaseDir = "/system/usr/share/zoneinfo/";
}
else version(Solaris)
{
/++
The default directory where the TZ Database files are. It's empty
for Windows, since Windows doesn't have them.
+/
enum defaultTZDatabaseDir = "/usr/share/lib/zoneinfo/";
}
else version(Posix)
{
/++
Expand Down

0 comments on commit 9f8482a

Please sign in to comment.