Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions benchmarks/Benchmark.hs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import qualified Data.ByteString.Lazy as L
import Data.Binary
import Data.Binary.Put
import Data.Binary.Get
import Data.Word

import Control.Exception
import System.CPUTime
Expand Down
1 change: 1 addition & 0 deletions benchmarks/Get.hs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
import qualified Data.ByteString.Lazy as L
import Data.Bits
import Data.Char (ord)
import Data.List (foldl')

Check warning on line 9 in benchmarks/Get.hs

View workflow job for this annotation

GitHub Actions / build (9.14.1)

The import of ‘Data.List’ is redundant

Check warning on line 9 in benchmarks/Get.hs

View workflow job for this annotation

GitHub Actions / build (9.10.3)

The import of ‘Data.List’ is redundant

Check warning on line 9 in benchmarks/Get.hs

View workflow job for this annotation

GitHub Actions / build (9.12.2)

The import of ‘Data.List’ is redundant
import Data.Word
import Test.Tasty.Bench

import Control.Applicative
Expand Down
3 changes: 1 addition & 2 deletions benchmarks/Put.hs
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,14 @@ import Control.Exception (evaluate)
import qualified Data.ByteString as S
import qualified Data.ByteString.Char8 as C
import qualified Data.ByteString.Lazy as L
import Data.Monoid
import Data.Word
import Test.Tasty.Bench

import GHC.Generics

import Data.Binary
import Data.Binary.Put
import Data.ByteString.Builder as BB
import Prelude -- Silence Monoid import warning.

main :: IO ()
main = do
Expand Down
7 changes: 6 additions & 1 deletion changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
binary
======

binary-0.9.0.0
--------------

- Don't reexport `Data.Word` from `Data.Binary`

binary-0.8.9.2
--------------

Expand Down Expand Up @@ -170,7 +175,7 @@ binary-0.7.1.0
--------------

- Add `lookAheadE :: Get (Either a b) -> Get (Either a b)`.
- Add MonadPlus instance for Get.
- Add MonadPlus instance for Get.


binary-0.7.0.1
Expand Down
4 changes: 0 additions & 4 deletions src/Data/Binary.hs
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,8 @@ module Data.Binary (
, decodeFile -- :: Binary a => FilePath -> IO a
, decodeFileOrFail

, module Data.Word -- useful

) where

import Data.Word

import Data.Binary.Class
import Data.Binary.Put
import Data.Binary.Get
Expand Down
5 changes: 3 additions & 2 deletions tests/File.hs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import Distribution.Simple.Utils (withTempDirectory)
import Distribution.Verbosity (silent)

import Data.Binary
import Data.Word

data Foo = Bar !Word32 !Word32 !Word32 deriving (Eq, Show)

Expand All @@ -38,6 +39,6 @@ readWriteTest = TestCase $ do
exampleData @=? content

main :: IO ()
main = do
main = do
_ <- runTestTT readWriteTest
return ()
return ()
1 change: 1 addition & 0 deletions tests/QC.hs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@
#endif
import Data.Int
import Data.Ratio
import Data.Typeable

Check warning on line 24 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (8.2.2)

The import of ‘Data.Typeable’ is redundant

Check warning on line 24 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (8.0.2)

The import of ‘Data.Typeable’ is redundant
import Data.Word
import System.IO.Unsafe

import Data.Orphans ()
Expand Down Expand Up @@ -180,7 +181,7 @@
, typeRep (Proxy :: Proxy (() -> ()))
]

instance Arbitrary TypeRep where

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (8.4.4)

Orphan instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (9.8.4)

Orphan class instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (8.8.4)

Orphan instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (9.2.8)

Orphan instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (9.4.8)

Orphan instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (8.10.7)

Orphan instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (9.14.1)

Orphan class instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (9.10.3)

Orphan class instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (9.6.7)

Orphan instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (8.6.5)

Orphan instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (9.12.2)

Orphan class instance: instance Arbitrary TypeRep

Check warning on line 184 in tests/QC.hs

View workflow job for this annotation

GitHub Actions / build (9.0.2)

Orphan instance: instance Arbitrary TypeRep
arbitrary = oneof (map pure atomicTypeReps)
#else
testTypeable :: Test
Expand Down
Loading