compensated 0.4.1 → 0.5
raw patch · 2 files changed
+7/−5 lines, 2 filesdep ~bifunctorsdep ~comonaddep ~log-domain
Dependency ranges changed: bifunctors, comonad, log-domain, semigroupoids
Files
- compensated.cabal +5/−5
- src/Numeric/Compensated.hs +2/−0
compensated.cabal view
@@ -1,6 +1,6 @@ name: compensated category: Numeric-version: 0.4.1+version: 0.5 license: BSD3 cabal-version: >= 1.8 license-file: LICENSE@@ -42,18 +42,18 @@ library build-depends: base >= 4.3 && < 5,- bifunctors >= 3.2 && < 4,+ bifunctors >= 4 && < 5, binary >= 0.5 && < 0.8, bytes >= 0.7 && < 1, cereal >= 0.3.5 && < 0.4,- comonad >= 3 && < 4,+ comonad >= 4 && < 5, deepseq >= 1.3 && < 1.5, distributive >= 0.3 && < 1, generic-deriving >= 1.4 && < 1.6, hashable >= 1.1.2.3 && < 1.3, lens >= 3.8 && < 4,- log-domain >= 0.3.0.1 && < 1,- semigroupoids >= 3.0.2 && < 4,+ log-domain >= 0.8 && < 1,+ semigroupoids >= 4 && < 5, semigroups >= 0.8.4 && < 1, safecopy >= 0.8.1 && < 0.9, vector >= 0.9 && < 0.11
src/Numeric/Compensated.hs view
@@ -311,10 +311,12 @@ uncompensated c = with c const {-# INLINE uncompensated #-} +{- type instance Index (Compensated a) = Int instance (Applicative f, Compensable a, Compensable b) => Each f (Compensated a) (Compensated b) a b where each f m = with m $ \a b -> compensated <$> L.indexed f (0 :: Int) a <*> L.indexed f (1 :: Int) b {-# INLINE each #-}+-} instance Compensable a => Eq (Compensated a) where m == n = with m $ \a b -> with n $ \c d -> a == c && b == d