binary-tagged 0.1.0.0 → 0.1.1.0
raw patch · 2 files changed
+25/−2 lines, 2 filesdep ~aesonPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: aeson
API changes (from Hackage documentation)
+ Data.Binary.Tagged: instance HasSemanticVersion Bool
+ Data.Binary.Tagged: instance HasSemanticVersion Char
+ Data.Binary.Tagged: instance HasSemanticVersion Int
+ Data.Binary.Tagged: instance HasSemanticVersion Int16
+ Data.Binary.Tagged: instance HasSemanticVersion Int32
+ Data.Binary.Tagged: instance HasSemanticVersion Int64
+ Data.Binary.Tagged: instance HasSemanticVersion Int8
+ Data.Binary.Tagged: instance HasSemanticVersion Integer
+ Data.Binary.Tagged: instance HasSemanticVersion Word
+ Data.Binary.Tagged: instance HasSemanticVersion Word16
+ Data.Binary.Tagged: instance HasSemanticVersion Word32
+ Data.Binary.Tagged: instance HasSemanticVersion Word64
+ Data.Binary.Tagged: instance HasSemanticVersion Word8
+ Data.Binary.Tagged: instance HasSemanticVersion a => HasSemanticVersion (Ratio a)
+ Data.Binary.Tagged: instance HasStructuralInfo Word
+ Data.Binary.Tagged: instance HasStructuralInfo a => HasStructuralInfo (Ratio a)
Files
- binary-tagged.cabal +2/−2
- src/Data/Binary/Tagged.hs +23/−0
binary-tagged.cabal view
@@ -3,9 +3,9 @@ -- see: https://github.com/sol/hpack name: binary-tagged-version: 0.1.0.0+version: 0.1.1.0 synopsis: Tagged binary serialisation.-description: Write me.+description: Check <https://github.com/phadej/binary-tagged#readme README on Github> category: Web homepage: https://github.com/phadej/binary-tagged#readme bug-reports: https://github.com/phadej/binary-tagged/issues
src/Data/Binary/Tagged.hs view
@@ -122,6 +122,7 @@ import qualified Data.IntMap as IntMap import qualified Data.IntSet as IntSet import qualified Data.Map as Map+import qualified Data.Ratio as Ratio import qualified Data.Sequence as Seq import qualified Data.Set as Set import qualified Data.HashSet as HS@@ -337,6 +338,7 @@ instance HasStructuralInfo Bool where structuralInfo = ghcNominalType instance HasStructuralInfo Char where structuralInfo = ghcNominalType instance HasStructuralInfo Int where structuralInfo = ghcNominalType+instance HasStructuralInfo Word where structuralInfo _ = NominalType "Word" instance HasStructuralInfo Integer where structuralInfo _ = NominalType "Integer" instance HasStructuralInfo Int8 where structuralInfo _ = NominalType "Int8"@@ -349,6 +351,22 @@ instance HasStructuralInfo Word32 where structuralInfo _ = NominalType "Word32" instance HasStructuralInfo Word64 where structuralInfo _ = NominalType "Word64" +instance HasSemanticVersion Bool+instance HasSemanticVersion Char+instance HasSemanticVersion Int+instance HasSemanticVersion Word+instance HasSemanticVersion Integer++instance HasSemanticVersion Int8+instance HasSemanticVersion Int16+instance HasSemanticVersion Int32+instance HasSemanticVersion Int64++instance HasSemanticVersion Word8+instance HasSemanticVersion Word16+instance HasSemanticVersion Word32+instance HasSemanticVersion Word64+ -- Recursive types instance HasStructuralInfo a => HasStructuralInfo [a] where structuralInfo = ghcStructuralInfo1 instance HasSemanticVersion a => HasSemanticVersion [a] where@@ -358,6 +376,11 @@ instance HasStructuralInfo a => HasStructuralInfo (Maybe a) instance HasSemanticVersion a => HasSemanticVersion (Maybe a) where type SemanticVersion (Maybe a) = SemanticVersion a++instance HasStructuralInfo a => HasStructuralInfo (Ratio.Ratio a) where+ structuralInfo _ = NominalNewtype "Ratio" $ structuralInfo (Proxy :: Proxy a)+instance HasSemanticVersion a => HasSemanticVersion (Ratio.Ratio a) where+ type SemanticVersion (Ratio.Ratio a) = SemanticVersion a instance (HasStructuralInfo a, HasStructuralInfo b) => HasStructuralInfo (Either a b) instance (HasSemanticVersion a, HasSemanticVersion b, KnownNat (SemanticVersion (Either a b))) => HasSemanticVersion (Either a b) where