packages feed

dhall-toml 1.0.2 → 1.0.3

raw patch · 7 files changed

+14/−3 lines, 7 filesdep ~containersdep ~dhalldep ~optparse-applicativePVP ok

version bump matches the API change (PVP)

Dependency ranges changed: containers, dhall, optparse-applicative, tasty, text

API changes (from Hackage documentation)

Files

CHANGELOG.md view
@@ -1,3 +1,7 @@+1.0.3++* [Support `Integer`s](https://github.com/dhall-lang/dhall-haskell/pull/2469)+ 1.0.2  * [Improve command-line interface](https://github.com/dhall-lang/dhall-haskell/pull/2355)
dhall-toml.cabal view
@@ -1,12 +1,12 @@ Name:               dhall-toml-Version:            1.0.2+Version:            1.0.3 Cabal-Version:      >=1.10 Build-Type:         Simple License:            BSD3 License-File:       LICENSE Copyright:          2021 ear7h Author:             ear7h-Maintainer:         Gabriel439@gmail.com+Maintainer:         GenuineGabriella@gmail.com Bug-Reports:        https://github.com/dhall-lang/dhall-haskell/issues Synopsis:           Convert between Dhall and TOML Description:@@ -35,7 +35,7 @@     Hs-Source-Dirs:   src     Build-Depends:         base                 >= 4.12     && < 5    ,-        dhall                >= 1.39.0   && < 1.42 ,+        dhall                >= 1.39.0   && < 1.43 ,         tomland              >= 1.3.2.0  && < 1.4  ,         text                 >= 0.11.1.0 && < 2.1  ,         containers           >= 0.5.9    && < 0.7  ,
src/Dhall/DhallToToml.hs view
@@ -265,6 +265,7 @@ toToml toml key expr  = case expr of     Core.BoolLit a -> return $ insertPrim (Toml.Value.Bool a)     Core.NaturalLit a -> return $ insertPrim (Toml.Value.Integer $ toInteger a)+    Core.IntegerLit a -> return $ insertPrim (Toml.Value.Integer a)     Core.DoubleLit (DhallDouble a) -> return $ insertPrim (Toml.Value.Double a)     Core.TextLit (Core.Chunks [] a) -> return $ insertPrim (Toml.Value.Text a)     Core.App Core.None _ -> return toml@@ -327,6 +328,7 @@         -- be represented as inline tables.         isInline v = case v of             Core.BoolLit _    -> True+            Core.IntegerLit _ -> True             Core.NaturalLit _ -> True             Core.DoubleLit _  -> True             Core.TextLit _    -> True@@ -348,6 +350,7 @@         toAny :: Expr Void Void -> Either CompileError Toml.AnyValue.AnyValue         toAny e = case e of             Core.BoolLit x                  -> rightAny $ Toml.Value.Bool x+            Core.IntegerLit x               -> rightAny $ Toml.Value.Integer x             Core.NaturalLit x               -> rightAny $ Toml.Value.Integer $ toInteger x             Core.DoubleLit (DhallDouble x)  -> rightAny $ Toml.Value.Double x             Core.TextLit (Core.Chunks [] x) -> rightAny $ Toml.Value.Text x
src/Dhall/TomlToDhall.hs view
@@ -171,6 +171,7 @@ tomlValueToDhall :: Expr Src Void -> Value t -> Either CompileError (Expr Src Void) tomlValueToDhall exprType v = case (exprType, v) of     (Core.Bool                , Value.Bool a   ) -> Right $ Core.BoolLit a+    (Core.Integer             , Value.Integer a) -> Right $ Core.IntegerLit a     (Core.Natural             , Value.Integer a) -> Right $ Core.NaturalLit $ fromInteger a     (Core.Double              , Value.Double a ) -> Right $ Core.DoubleLit $ DhallDouble a     (Core.Text                , Value.Text a   ) -> Right $ Core.TextLit $ Core.Chunks [] a
tasty/data/inline-list-schema.dhall view
@@ -3,6 +3,7 @@ , lists : List (List Natural) , nested :     { floats : List Double+    , ints : List Integer     , moreLists : List (List Natural)     } , nested1 :
tasty/data/inline-list.dhall view
@@ -3,6 +3,7 @@ , lists = [[1, 2], [3, 4], [] : List Natural] , nested =     { floats = [1.1, 2.2]+    , ints = [-5, +2]     , moreLists = [[1, 2], [3, 4], [] : List Natural]     } , nested1 =
tasty/data/inline-list.toml view
@@ -4,6 +4,7 @@  [nested] floats = [1.1, 2.2]+ints = [-5, 2] moreLists = [[1, 2], [3, 4], []]  [nested1]