OddWord 1.0.1.0 → 1.0.1.1
raw patch · 5 files changed
+68/−32 lines, 5 filesdep +criteriondep ~OddWorddep ~QuickCheckPVP: major bump suggested
API removals or changes: PVP suggests a major version bump
Dependencies added: criterion
Dependency ranges changed: OddWord, QuickCheck
API changes (from Hackage documentation)
- Data.Word.Odd: instance GHC.TypeLits.KnownNat a => Data.Word.Odd.TypeNum (Data.Word.Odd.TypeLits.Lit a)
+ Data.Word.Odd: instance GHC.TypeNats.KnownNat a => Data.Word.Odd.TypeNum (Data.Word.Odd.TypeLits.Lit a)
Files
- CHANGELOG +32/−0
- LICENSE +1/−1
- NEWS +0/−25
- OddWord.cabal +16/−6
- bench/Main.hs +19/−0
+ CHANGELOG view
@@ -0,0 +1,32 @@+OddWord - Release History++release-1.0.1.1 - 2018.04.05++ * Added criterion benchmark+ * Renamed NEWS file to CHANGELOG.+ * Relaxed QuickCheck version constraint.++release-1.0.1.0 - 2015.10.25++ * Added optional support for GHC type-level literals.+ * Added FiniteBits instance.+ * Added more test coverage.+ * Fixed bug in toEnum function and extended test suite. (Thanks to Pasqualino+ "Titto" Assini)+ * Fixed warnings when compiling test suite with base-4.7 (GHC 7.8).+ * Relaxed QuickCheck version constraint.++release-1.0.0.2 - 2013.05.14++ * Fixed misdefinition of type synonyms for Word10, Word12, and Word14,+ and extended test suite. (Thanks to Benno Fünfstück)++release-1.0.0.1 - 2012.12.30++ * Fixed compilation with base-4.6 (GHC 7.6).+ * Fixed bug in Read instance and extended test suite. (Thanks to Tikhon+ Jelvis)++release-1.0.0 - 2011.07.21++ * Initial release.
LICENSE view
@@ -1,7 +1,7 @@ The following license covers this documentation, and the source code, except where otherwise indicated. -Copyright 2011-2015, Robin KAY. All rights reserved.+Copyright 2011-2018, Robin KAY. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
− NEWS
@@ -1,25 +0,0 @@-OddWord - Release History--release-1.0.1.0 - 2015.10.25-- * Added optional support for GHC type-level literals.- * Added FiniteBits instance.- * Added more test coverage.- * Fixed bug in toEnum function and extended test suite. (Thanks to Pasqualino "Titto" Assini)- * Fixed warnings when compiling test suite with base-4.7 (GHC 7.8).- * Relaxed QuickCheck version constraint.--release-1.0.0.2 - 2013.05.14-- * Fixed misdefinition of type synonyms for Word10, Word12, and Word14,- and extended test suite. (Thanks to Benno Fünfstück)--release-1.0.0.1 - 2012.12.30-- * Fixed compilation with base-4.6 (GHC 7.6).- * Fixed bug in Read instance and extended test suite. (Thanks to Tikhon- Jelvis)--release-1.0.0 - 2011.07.21-- * Initial release.
OddWord.cabal view
@@ -1,8 +1,8 @@ name: OddWord-version: 1.0.1.0+version: 1.0.1.1 license: BSD3 license-file: LICENSE-copyright: (c) 2011-2015 Robin KAY+copyright: (c) 2011-2018 Robin KAY author: Robin KAY maintainer: Robin KAY <komadori@gekkou.co.uk> synopsis: Provides a wrapper for deriving word types with fewer bits.@@ -10,7 +10,7 @@ stability: Stable cabal-version: >= 1.10 build-type: Simple-extra-source-files: test/*.hs NEWS+extra-source-files: test/*.hs bench/*.hs CHANGELOG homepage: http://www.gekkou.co.uk/ description: Provdes the 'OddWord' type, which wraps an existing integer type and@@ -40,8 +40,8 @@ other-extensions: ScopedTypeVariables CPP build-depends: base >= 4.5 && < 5,- QuickCheck >= 2.4 && < 2.9,- OddWord >= 1.0 && < 1.1+ QuickCheck >= 2.4 && < 2.12,+ OddWord Test-Suite oddword-tests-typelits type: exitcode-stdio-1.0@@ -52,9 +52,19 @@ buildable: True build-depends: base >= 4.5 && < 5,- OddWord >= 1.0 && < 1.1+ OddWord else buildable: False++Benchmark oddword-bench+ type: exitcode-stdio-1.0+ hs-source-dirs: bench+ main-is: Main.hs+ default-language: Haskell2010+ build-depends:+ base >= 4.5 && < 5,+ criterion >= 1.4 && < 1.5,+ OddWord Source-repository head type: darcs
+ bench/Main.hs view
@@ -0,0 +1,19 @@+module Main where++import Data.Word+import Data.Word.Odd+import Criterion.Main++testAddMul :: (Num a) => a -> a+testAddMul n = 2*n*n + 3*n + 4++main :: IO ()+main =+ defaultMain [+ bgroup "Word" [+ bench "addMul" $ whnf testAddMul (1::Word)+ ],+ bgroup "Word20" [+ bench "addMul" $ whnf testAddMul (1::Word20)+ ]+ ]