Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

cleanup

  • Loading branch information...
commit 7b022f4414edf938b6b73f29b1835b76f1d4d6b7 1 parent a751ee8
@atzedijkstra atzedijkstra authored
Showing with 8 additions and 23 deletions.
  1. +8 −23 src/UHC/Util/Time.hs
View
31 src/UHC/Util/Time.hs
@@ -1,34 +1,20 @@
-{-# LANGUAGE CPP #-}
-
--- wrapping around different versions of directory, enforcing different time packages to be used.
-
-#define DIRECTORY_USES_UTCTIME 1
+-- wrapping around time to look like old-time, only for that what is being used.
module UHC.Util.Time
- (
- module Data.Time.Compat,
-# ifdef DIRECTORY_USES_UTCTIME
- module Data.Time,
- module Data.Time.Clock,
- ClockTime,
- diffClockTimes,
- noTimeDiff,
- getClockTime
-# else
- module System.Time
-# endif
+ ( module Data.Time.Compat,
+ module Data.Time,
+ module Data.Time.Clock,
+ ClockTime,
+ diffClockTimes,
+ noTimeDiff,
+ getClockTime
)
where
-#ifdef DIRECTORY_USES_UTCTIME
import Data.Time
import Data.Time.Clock
-#else
-import System.Time
-#endif
import Data.Time.Compat
-#ifdef DIRECTORY_USES_UTCTIME
-- | a for now alias for old-time ClockTime
type ClockTime = UTCTime
@@ -39,5 +25,4 @@ noTimeDiff = toEnum 0
getClockTime :: IO ClockTime
getClockTime = getCurrentTime
-#endif
Please sign in to comment.
Something went wrong with that request. Please try again.