Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

Commit

Permalink
Fix bug# 14546.
Browse files Browse the repository at this point in the history
This makes it so that ClockType isn't actually used in core.time in the
documentation build (since if it is, it triggers static assertions,
since none of the systems support all of the ClockTypes, but they all
have to be defined for the documentation build in order to show up in
the docs).
  • Loading branch information
jmdavis committed May 8, 2015
1 parent 2c74db0 commit ab3ed25
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/core/time.d
Expand Up @@ -2648,7 +2648,14 @@ private immutable long[__traits(allMembers, ClockType).length] _ticksPerSecond;

@trusted shared static this()
{
version(Windows)
// If we try to do anything with ClockType in the documentation build, it'll
// trigger the static assertions related to ClockType, since the
// documentation build defines all of the possible ClockTypes, which won't
// work when they're used in the static ifs, because no system supports them
// all.
version(CoreDdoc)
{}
else version(Windows)
{
long ticksPerSecond;
if(QueryPerformanceFrequency(&ticksPerSecond) != 0)
Expand Down

0 comments on commit ab3ed25

Please sign in to comment.