o-clock 1.0.0 → 1.0.0.1
raw patch · 7 files changed
+29/−13 lines, 7 filesdep ~Globdep ~aesondep ~basesetup-changedPVP: major bump suggested
API removals or changes: PVP suggests a major version bump
Dependency ranges changed: Glob, aeson, base, deepseq, doctest, ghc-prim, hashable, hedgehog, tasty, tasty-hedgehog
API changes (from Hackage documentation)
- Time.Series: instance (Time.Units.KnownRatName unit, Time.Series.SeriesF (nextUnit : units)) => Time.Series.SeriesF (unit : nextUnit : units)
- Time.Series: instance (Time.Units.KnownRatName unit, Time.Series.SeriesP (nextUnit : units)) => Time.Series.SeriesP (unit : nextUnit : units)
- Time.Units: instance Data.Semigroup.Semigroup (Time.Units.Time rat)
+ Time.Rational: withRuntimeDivRat :: forall (a :: Rat) (b :: Rat) r. (KnownRat a, KnownRat b) => (KnownRat (a / b) => r) -> r
+ Time.Series: instance (Time.Units.KnownRatName unit, Time.Series.SeriesF (nextUnit : units), Time.Series.DescendingConstraint (Time.Series.IsDescending (unit : nextUnit : units))) => Time.Series.SeriesF (unit : nextUnit : units)
+ Time.Series: instance (Time.Units.KnownRatName unit, Time.Series.SeriesP (nextUnit : units), Time.Series.DescendingConstraint (Time.Series.IsDescending (unit : nextUnit : units))) => Time.Series.SeriesP (unit : nextUnit : units)
+ Time.Units: instance GHC.Base.Semigroup (Time.Units.Time rat)
- Time.Rational: type KnownDivRat a b = (KnownRat a, KnownRat b)
+ Time.Rational: type KnownDivRat a b = (KnownRat a, KnownRat b, KnownRat (a / b))
- Time.Units: type Day = 86400 :% 1
+ Time.Units: type Day = 24 * Hour
- Time.Units: type Fortnight = 1209600 :% 1
+ Time.Units: type Fortnight = 2 * Week
- Time.Units: type Hour = 3600 :% 1
+ Time.Units: type Hour = 60 * Minute
- Time.Units: type Microsecond = 1 :% 1000000
+ Time.Units: type Microsecond = Millisecond / 1000
- Time.Units: type Millisecond = 1 :% 1000
+ Time.Units: type Millisecond = Second / 1000
- Time.Units: type Minute = 60 :% 1
+ Time.Units: type Minute = 60 * Second
- Time.Units: type Nanosecond = 1 :% 1000000000
+ Time.Units: type Nanosecond = Microsecond / 1000
- Time.Units: type Picosecond = 1 :% 1000000000000
+ Time.Units: type Picosecond = Nanosecond / 1000
- Time.Units: type Second = 1 :% 1
+ Time.Units: type Second = 1 / 1
- Time.Units: type Week = 604800 :% 1
+ Time.Units: type Week = 7 * Day
Files
- CHANGELOG.md +5/−0
- README.lhs +3/−0
- README.md +3/−0
- Setup.hs +0/−2
- o-clock.cabal +11/−10
- src/Time/Rational.hs +3/−0
- src/Time/Units.hs +4/−1
CHANGELOG.md view
@@ -3,6 +3,11 @@ o'clock uses [PVP Versioning][1]. The change log is available [on GitHub][2]. +1.0.0.1+=======++* Add support for GHC-8.6.1+ 1.0.0 =====
README.lhs view
@@ -76,6 +76,9 @@ ```haskell {-# LANGUAGE CPP #-} {-# LANGUAGE DataKinds #-}+#if ( __GLASGOW_HASKELL__ >= 806 )+{-# LANGUAGE NoStarIsType #-}+#endif {-# LANGUAGE TypeApplications #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeOperators #-}
README.md view
@@ -76,6 +76,9 @@ ```haskell {-# LANGUAGE CPP #-} {-# LANGUAGE DataKinds #-}+#if ( __GLASGOW_HASKELL__ >= 806 )+{-# LANGUAGE NoStarIsType #-}+#endif {-# LANGUAGE TypeApplications #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeOperators #-}
− Setup.hs
@@ -1,2 +0,0 @@-import Distribution.Simple-main = defaultMain
o-clock.cabal view
@@ -1,5 +1,5 @@ name: o-clock-version: 1.0.0+version: 1.0.0.1 synopsis: Type-safe time library. description: See README.md for details. homepage: https://github.com/serokell/o-clock@@ -19,6 +19,7 @@ tested-with: GHC == 8.0.2 , GHC == 8.2.2 , GHC == 8.4.3+ , GHC == 8.6.1 source-repository head type: git@@ -33,7 +34,7 @@ Time.Units ghc-options: -Wall build-depends: base >= 4.9 && < 5- , ghc-prim >= 0.5+ , ghc-prim ^>= 0.5 default-language: Haskell2010 default-extensions: OverloadedStrings RecordWildCards@@ -41,14 +42,14 @@ TypeApplications TypeFamilies if flag(aeson)- build-depends: aeson >= 1.2.4+ build-depends: aeson >= 1.2.4 && < 1.5 , text cpp-options: -DHAS_aeson if flag(hashable)- build-depends: hashable >= 1.2.6+ build-depends: hashable >= 1.2.6 && < 1.3 cpp-options: -DHAS_hashable if flag(deepseq)- build-depends: deepseq >= 1.4+ build-depends: deepseq ^>= 1.4 cpp-options: -DHAS_deepseq if flag(serialise) build-depends: serialise >= 0.2@@ -75,9 +76,9 @@ build-depends: base >= 4.9 && < 5 , o-clock- , hedgehog ^>= 0.5.1- , tasty ^>= 0.12- , tasty-hedgehog ^>= 0.1+ , hedgehog ^>= 0.6+ , tasty >= 0.12 && < 1.2+ , tasty-hedgehog >= 0.1 && < 0.3 , tasty-hspec ^>= 1.1.3 , type-spec ^>= 0.3.0.1 @@ -93,8 +94,8 @@ build-tool-depends: doctest:doctest build-depends: base >= 4.10 && < 5- , doctest >= 0.13- , Glob >= 0.9+ , doctest ^>= 0.16+ , Glob ^>= 0.9 ghc-options: -Wall -threaded -rtsopts -with-rtsopts=-N default-language: Haskell2010
src/Time/Rational.hs view
@@ -4,6 +4,9 @@ {-# LANGUAGE TypeInType #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE FlexibleInstances #-}+#if ( __GLASGOW_HASKELL__ >= 806 )+{-# LANGUAGE NoStarIsType #-}+#endif {-# LANGUAGE Rank2Types #-} {-# LANGUAGE TypeOperators #-} {-# LANGUAGE UndecidableInstances #-}
src/Time/Units.hs view
@@ -5,8 +5,11 @@ {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE ExplicitForAll #-} {-# LANGUAGE FlexibleContexts #-}-{-# LANGUAGE InstanceSigs #-} {-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE InstanceSigs #-}+#if ( __GLASGOW_HASKELL__ >= 806 )+{-# LANGUAGE NoStarIsType #-}+#endif {-# LANGUAGE TypeOperators #-} {-# LANGUAGE UndecidableInstances #-}