Safe Haskell | None |
---|---|
Language | Haskell2010 |
OM.Time
Description
Basic missing time utilities.
Documentation
class Monad m => MonadTimeSpec (m :: Type -> Type) where Source #
A monad that can produce the current time as a TimeSpec.
Instances
MonadTimeSpec IO Source # | The IO instances uses |
Monad m => MonadTimeSpec (NowT m) Source # | |
(Monad (t m), MonadTimeSpec m, MonadTrans t) => MonadTimeSpec (t m) Source # | |
timed :: MonadTimeSpec m => m a -> m (a, DiffTime) Source #
Perform an action and measure how long it takes.
diffTimeSpec :: TimeSpec -> TimeSpec -> DiffTime Source #
Take the difference of two time specs, as a DiffTime
.
data NowT (m :: Type -> Type) a Source #
An instance of MonadTimeSpec where the time is always a constant value.