waargonaut 0.8.0.0 → 0.8.0.1
raw patch · 3 files changed
+30/−17 lines, 3 filesdep ~basedep ~generics-sopdep ~lensnew-uploaderPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: base, generics-sop, lens
API changes (from Hackage documentation)
Files
- changelog.md +7/−1
- src/Waargonaut/Generic.hs +13/−7
- waargonaut.cabal +10/−9
changelog.md view
@@ -1,5 +1,11 @@ # Revision history for waargonaut +## 0.8.0.1 -- 2019-09-22++* Support GHC 8.8.1++* Support generics-sop 0.5+ ## 0.8.0.0 -- 2019-09-04 * Add `onObj'` which is just `onObj` but specialised to `Identity`.@@ -19,7 +25,7 @@ * Change the building of escaped whitespace chars to actually use the `escapedWhitespaceChar` function, instead of incorrectly generating an unescaped character.- + * Add haddock to gObjEncoder function * Correctly bump version to 0.8.0.0 as this is a breaking change because of new
src/Waargonaut/Generic.hs view
@@ -1,3 +1,4 @@+{-# LANGUAGE CPP #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE DefaultSignatures #-} {-# LANGUAGE FlexibleContexts #-}@@ -263,10 +264,10 @@ -- @ -- newtype Foo = Foo Text --- -- let x = Foo "Fred"+ -- let x = Foo \"Fred\" -- @ --- -- Will be encoded as: @ "Fred" @+ -- Will be encoded as: @ \"Fred\" @ -- = Unwrap @@ -275,10 +276,10 @@ -- @ -- newtype Foo = Foo Text --- -- let x = Foo "Fred"+ -- let x = Foo \"Fred\" -- @ --- -- Will be encoded as: @ {"Foo":"Fred"} @+ -- Will be encoded as: @ {\"Foo\":\"Fred\"} @ -- | ConstructorNameAsKey @@ -288,10 +289,10 @@ -- @ -- newtype Foo = Foo { deFoo :: Text } --- -- let x = Foo "Fred"+ -- let x = Foo \"Fred\" -- @ --- -- Will be encoded as: @ {"deFoo":"Fred"} @+ -- Will be encoded as: @ {\"deFoo\":\"Fred\"} @ | FieldNameAsKey deriving (Show, Eq) @@ -483,7 +484,12 @@ ConstructorNameAsKey -> JsonOne (Tag $ _optionsFieldName opts n) :* Nil FieldNameAsKey -> jInfoFor opts n (Tag . _optionsFieldName opts) c :* Nil - ADT _ n cs -> hliftA (jInfoFor opts n (tag cs)) cs+#if MIN_VERSION_generics_sop(0,5,0)+ ADT _ n cs _+#else+ ADT _ n cs+#endif+ -> hliftA (jInfoFor opts n (tag cs)) cs where tag :: NP ConstructorInfo (Code a) -> ConstructorName -> Tag tag (_ :* Nil) = const NoTag
waargonaut.cabal view
@@ -10,7 +10,7 @@ -- PVP summary: +-+------- breaking API changes -- | | +----- non-breaking API additions -- | | | +--- code changes with no API change-version: 0.8.0.0+version: 0.8.0.1 -- A short (one-line) description of the package. synopsis: JSON wrangling@@ -75,7 +75,8 @@ tested-with: GHC==8.0.2 , GHC==8.2.2 , GHC==8.4.4- , GHC==8.6.4+ , GHC==8.6.5+ , GHC==8.8.1 custom-setup setup-depends: base >= 4.9 && <5@@ -143,8 +144,8 @@ ghc-options: -Wall -- Other library packages from which modules are imported.- build-depends: base >= 4.9 && < 4.13- , lens >= 4.15 && < 4.18+ build-depends: base >= 4.9 && < 4.14+ , lens >= 4.15 && < 4.19 , mtl >= 2.2.2 && < 2.3 , text >= 1.2 && < 1.3 , bytestring >= 0.10.6 && < 0.11@@ -160,7 +161,7 @@ , hoist-error >= 0.2 && < 0.3 , containers >= 0.5.6 && < 0.7 , witherable >= 0.2 && < 0.4- , generics-sop >= 0.4 && < 0.5+ , generics-sop >= 0.4 && < 0.6 , records-sop >= 0.1 && < 0.2 , mmorph >= 1.1 && < 1.2 , transformers >= 0.4 && < 0.6@@ -190,7 +191,7 @@ default-language: Haskell2010 hs-source-dirs: test - build-depends: base >= 4.9 && < 4.13+ build-depends: base >= 4.9 && < 4.14 , hedgehog >= 0.6 && < 1.2 , text >= 1.2 && < 1.3 , digit >= 0.7 && < 0.9@@ -229,14 +230,14 @@ main-is: Main.hs hs-source-dirs: test - build-depends: base >= 4.9 && < 4.13+ build-depends: base >= 4.9 && < 4.14 , tasty >= 0.11 && < 1.3 , tasty-hunit >= 0.10 && < 0.11 , tasty-expected-failure >= 0.11 && < 0.12 , hedgehog >= 0.6 && < 1.2 , hedgehog-fn >= 0.6 && < 2 , tasty-hedgehog >= 0.2 && < 1.2- , lens >= 4.15 && < 4.18+ , lens >= 4.15 && < 4.19 , distributive >= 0.5 && < 0.7 , bytestring >= 0.10.6 && < 0.11 , digit >= 0.7 && < 0.9@@ -244,7 +245,7 @@ , semigroups >= 0.8.4 && < 0.20 , zippers >= 0.2 && < 0.4 , vector >= 0.12 && < 0.13- , generics-sop >= 0.4 && < 0.5+ , generics-sop >= 0.4 && < 0.6 , attoparsec >= 0.13 && < 0.15 , scientific >= 0.3 && < 0.4 , tagged >= 0.8.5 && < 0.9