packages feed

opaleye 0.9.6.0 → 0.9.6.1

raw patch · 4 files changed

+21/−5 lines, 4 filesPVP: minor bump suggested

API additions: PVP suggests at least a minor version bump

API changes (from Hackage documentation)

+ Opaleye.Internal.Aggregate: unsafeAvg :: Aggregator (Field a) (Field a)
+ Opaleye.Internal.Aggregate: unsafeMax :: Aggregator (Field a) (Field a)
+ Opaleye.Internal.Aggregate: unsafeMin :: Aggregator (Field a) (Field a)
+ Opaleye.Internal.Aggregate: unsafeSum :: Aggregator (Field a) (Field a)

Files

CHANGELOG.md view
@@ -1,3 +1,7 @@+## 0.9.6.1++* No externally visible changes+ ## 0.9.6.0  * Add `Opaleye.Window` to support window functions.  Thanks to Shane
opaleye.cabal view
@@ -1,6 +1,6 @@ name:            opaleye copyright:       Copyright (c) 2014-2018 Purely Agile Limited; 2019-2022 Tom Ellis-version:         0.9.6.0+version:         0.9.6.1 synopsis:        An SQL-generating DSL targeting PostgreSQL description:     An SQL-generating DSL targeting PostgreSQL.  Allows                  Postgres queries to be written within Haskell in a
src/Opaleye/Aggregate.hs view
@@ -115,7 +115,7 @@ -- runtime when the argument is 'T.SqlInt4' or 'T.SqlInt8'.  For those -- use 'sumInt4' or 'sumInt8' instead. sum :: Aggregator (F.Field a) (F.Field a)-sum = A.makeAggr HPQ.AggrSum+sum = A.unsafeSum  sumInt4 :: Aggregator (F.Field T.SqlInt4) (F.Field T.SqlInt8) sumInt4 = fmap F.unsafeCoerceField Opaleye.Aggregate.sum@@ -134,15 +134,15 @@  -- | Average of a group avg :: Aggregator (F.Field T.SqlFloat8) (F.Field T.SqlFloat8)-avg = A.makeAggr HPQ.AggrAvg+avg = A.unsafeAvg  -- | Maximum of a group max :: Ord.SqlOrd a => Aggregator (F.Field a) (F.Field a)-max = A.makeAggr HPQ.AggrMax+max = A.unsafeMax  -- | Maximum of a group min :: Ord.SqlOrd a => Aggregator (F.Field a) (F.Field a)-min = A.makeAggr HPQ.AggrMin+min = A.unsafeMin  boolOr :: Aggregator (F.Field T.SqlBool) (F.Field T.SqlBool) boolOr = A.makeAggr HPQ.AggrBoolOr
src/Opaleye/Internal/Aggregate.hs view
@@ -140,6 +140,18 @@    pure (HPQ.AttrExpr souter) +unsafeMax :: Aggregator (C.Field a) (C.Field a)+unsafeMax = makeAggr HPQ.AggrMax++unsafeMin :: Aggregator (C.Field a) (C.Field a)+unsafeMin = makeAggr HPQ.AggrMin++unsafeAvg :: Aggregator (C.Field a) (C.Field a)+unsafeAvg = makeAggr HPQ.AggrAvg++unsafeSum :: Aggregator (C.Field a) (C.Field a)+unsafeSum = makeAggr HPQ.AggrSum+ -- { Boilerplate instances  instance Functor (Aggregator a) where