transformers-compat 0.6.0.6 → 0.6.1.2
raw patch · 6 files changed
+155/−53 lines, 6 filesdep −QuickCheckdep −deriving-compatdep −hspecdep ~transformers
Dependencies removed: QuickCheck, deriving-compat, hspec, tagged, transformers-compat
Dependency ranges changed: transformers
Files
- .travis.yml +22/−20
- CHANGELOG.markdown +31/−0
- tests/GenericsTypes.hs +11/−4
- tests/LICENSE +30/−0
- tests/transformers-compat-tests.cabal +52/−0
- transformers-compat.cabal +9/−29
.travis.yml view
@@ -44,61 +44,61 @@ - compiler: "ghc-7.0.4" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-f-generic-deriving"+ env: CABALFLAGS="-f-generic-deriving" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4" env: CABALFLAGS="-f-mtl" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-f-generic-deriving -f-mtl"+ env: CABALFLAGS="-f-generic-deriving -f-mtl" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4" env: CABALFLAGS="-ftwo" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-ftwo -f-generic-deriving"+ env: CABALFLAGS="-ftwo -f-generic-deriving" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4" env: CABALFLAGS="-ftwo -f-mtl" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-ftwo -f-generic-deriving -f-mtl"+ env: CABALFLAGS="-ftwo -f-generic-deriving -f-mtl" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4" env: CABALFLAGS="-fthree" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-fthree -f-generic-deriving"+ env: CABALFLAGS="-fthree -f-generic-deriving" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4" env: CABALFLAGS="-fthree -f-mtl" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-fthree -f-generic-deriving -f-mtl"+ env: CABALFLAGS="-fthree -f-generic-deriving -f-mtl" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4" env: CABALFLAGS="-ffour" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-ffour -f-generic-deriving"+ env: CABALFLAGS="-ffour -f-generic-deriving" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4" env: CABALFLAGS="-ffour -f-mtl" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-ffour -f-generic-deriving -f-mtl"+ env: CABALFLAGS="-ffour -f-generic-deriving -f-mtl" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4" env: CABALFLAGS="-ffive" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-ffive -f-generic-deriving"+ env: CABALFLAGS="-ffive -f-generic-deriving" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4" env: CABALFLAGS="-ffive -f-mtl" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.0.4"- env: CABALFLAGS="-ffive -f-generic-deriving -f-mtl"+ env: CABALFLAGS="-ffive -f-generic-deriving -f-mtl" TEST=--disable-tests addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.0.4], sources: [hvr-ghc]}} - compiler: "ghc-7.2.2" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-7.2.2], sources: [hvr-ghc]}}@@ -172,14 +172,12 @@ - compiler: "ghc-8.2.2" addons: {apt: {packages: [*apt_packages,cabal-install-2.0,ghc-8.2.2], sources: [hvr-ghc]}} - compiler: "ghc-8.4.1"- env: GHCHEAD=true- addons: {apt: {packages: [*apt_packages,cabal-install-head,ghc-8.4.1], sources: [hvr-ghc]}}+ addons: {apt: {packages: [*apt_packages,cabal-install-2.2,ghc-8.4.1], sources: [hvr-ghc]}} - compiler: "ghc-head" env: GHCHEAD=true addons: {apt: {packages: [*apt_packages,cabal-install-head,ghc-head], sources: [hvr-ghc]}} allow_failures:- - compiler: "ghc-8.4.1" - compiler: "ghc-head" before_install:@@ -196,7 +194,7 @@ - cabal --version - echo "$(${HC} --version) [$(${HC} --print-project-git-commit-id 2> /dev/null || echo '?')]" - BENCH=${BENCH---enable-benchmarks}- - TEST=${TEST---disable-tests} # https://github.com/ekmett/transformers-compat/issues/24+ - TEST=${TEST---enable-tests} - HADDOCK=${HADDOCK-true} - INSTALLED=${INSTALLED-true} - GHCHEAD=${GHCHEAD-false}@@ -219,14 +217,16 @@ cabal new-update head.hackage -v fi - grep -Ev -- '^\s*--' ${HOME}/.cabal/config | grep -Ev '^\s*$'- - "printf 'packages: \".\"\\n' > cabal.project"+ - "printf 'packages: \".\" \"./tests\"\\n' > cabal.project" - cat cabal.project - if [ -f "./configure.ac" ]; then (cd "." && autoreconf -i); fi+ - if [ -f "./tests/configure.ac" ]; then+ (cd "./tests" && autoreconf -i);+ fi - rm -f cabal.project.freeze- - cabal new-build -w ${HC} ${CABALFLAGS} ${TEST} ${BENCH} --project-file="cabal.project" --dep -j2 all- - rm -rf "."/.ghc.environment.* "."/dist+ - rm -rf .ghc.environment.* "."/dist "./tests"/dist - DISTDIR=$(mktemp -d /tmp/dist-test.XXXX) # Here starts the actual work to be performed for the package under test;@@ -234,19 +234,21 @@ script: # test that source-distributions can be generated - (cd "." && cabal sdist)- - mv "."/dist/transformers-compat-*.tar.gz ${DISTDIR}/+ - (cd "./tests" && cabal sdist)+ - mv "."/dist/transformers-compat-*.tar.gz "./tests"/dist/transformers-compat-tests-*.tar.gz ${DISTDIR}/ - cd ${DISTDIR} || false - find . -maxdepth 1 -name '*.tar.gz' -exec tar -xvf '{}' \;- - "printf 'packages: transformers-compat-*/*.cabal\\n' > cabal.project"+ - "printf 'packages: transformers-compat-*/*.cabal transformers-compat-tests-*/*.cabal\\n' > cabal.project" - cat cabal.project # build & run tests, build benchmarks- - cabal new-build -w ${HC} ${CABALFLAGS} ${TEST} ${BENCH} all+ - cabal new-build -w ${HC} ${CABALFLAGS} ${TEST} ${BENCH} -j2 all - if [ "x$TEST" = "x--enable-tests" ]; then cabal new-test -w ${HC} ${CABALFLAGS} ${TEST} ${BENCH} all; fi # cabal check - (cd transformers-compat-* && cabal check)+ - (cd transformers-compat-tests-* && cabal check) # haddock - rm -rf ./dist-newstyle
CHANGELOG.markdown view
@@ -1,3 +1,34 @@+0.6.1.6+-------+* Each of versions 0.6.1.2–0.6.1.6 is a 0.6.1 build with a different set of flags configured. Building this way allows us to work around bugs in `cabal`'s backtracker. The 0.6.1 release notes describe the changes in this version.+ This release is configured with none of `-ftwo`, `-fthree`, `-ffour`, or `-ffive` (which works with `transformers-0.5.3` and above).++0.6.1.5+-------+* Each of versions 0.6.1.2–0.6.1.6 is a 0.6.1 build with a different set of flags configured. Building this way allows us to work around bugs in `cabal`'s backtracker. The 0.6.1 release notes describe the changes in this version.+ This release is configured with `-ffive` (which works with `transformers-0.5` up until, but not including, `transformers-0.5.3`).++0.6.1.4+-------+* Each of versions 0.6.1.2–0.6.1.6 is a 0.6.1 build with a different set of flags configured. Building this way allows us to work around bugs in `cabal`'s backtracker. The 0.6.1 release notes describe the changes in this version.+ This release is configured with `-ffour` (which works with the `transformers-0.4` series).++0.6.1.3+-------+* Each of versions 0.6.1.2–0.6.1.6 is a 0.6.1 build with a different set of flags configured. Building this way allows us to work around bugs in `cabal`'s backtracker. The 0.6.1 release notes describe the changes in this version.+ This release is configured with `-fthree` (which works with the `transformers-0.3` series).++0.6.1.2+-------+* Each of versions 0.6.1.2–0.6.1.6 is a 0.6.1 build with a different set of flags configured. Building this way allows us to work around bugs in `cabal`'s backtracker. The 0.6.1 release notes describe the changes in this version.+ This release is configured with `-ftwo` (which works with the `transformers-0.2` series).++0.6.1+-----+* Fix an oversight in which the `Control.Monad.Trans.Accum` and+ `Control.Monad.Trans.Select` modules were not backported when built with the+ `-ffour` flag.+ 0.6.0.6 ------- * Each of versions 0.6.0.2–0.6.0.6 is a 0.6 build with a different set of flags configured. Building this way allows us to work around bugs in `cabal`'s backtracker. The 0.6 release notes describe the changes in this version.
tests/GenericsTypes.hs view
@@ -29,7 +29,7 @@ import Test.QuickCheck (Arbitrary(..), oneof) -#if __GLASGOW_HASKELL__ < 702+#if __GLASGOW_HASKELL__ == 700 || __GLASGOW_HASKELL__ == 804 import Text.Read.Deriving (deriveRead) #endif @@ -105,11 +105,14 @@ , (:%:) <$> arbitrary <*> arbitrary ] -#if __GLASGOW_HASKELL__ >= 702-deriving instance Read a => Read (T# a)-#else+#if __GLASGOW_HASKELL__ == 700 -- Workaround for GHC Trac #5041 $(deriveRead ''T#)+#elif __GLASGOW_HASKELL__ == 804+-- Workaround for GHC Trac #14918+$(deriveRead ''T#)+#else+deriving instance Read a => Read (T# a) #endif #if __GLASGOW_HASKELL__ >= 706@@ -134,6 +137,10 @@ #define CLASS1_INSTANCE(class,type,method,impl) \ instance class type where { method = impl }; \++#if MIN_VERSION_transformers(0,4,0) && !(MIN_VERSION_transformers(0,5,0))+# define TRANSFORMERS_FOUR 1+#endif #if defined(TRANSFORMERS_FOUR) # define EQ1_INSTANCE(type) CLASS1_INSTANCE(Eq1,type,eq1,eq1Default)
+ tests/LICENSE view
@@ -0,0 +1,30 @@+Copyright 2012-2015 Edward Kmett++All rights reserved.++Redistribution and use in source and binary forms, with or without+modification, are permitted provided that the following conditions+are met:++1. Redistributions of source code must retain the above copyright+ notice, this list of conditions and the following disclaimer.++2. Redistributions in binary form must reproduce the above copyright+ notice, this list of conditions and the following disclaimer in the+ documentation and/or other materials provided with the distribution.++3. Neither the name of the author nor the names of his contributors+ may be used to endorse or promote products derived from this software+ without specific prior written permission.++THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS OR+IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE+DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE FOR+ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS+OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)+HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,+STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN+ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE+POSSIBILITY OF SUCH DAMAGE.
+ tests/transformers-compat-tests.cabal view
@@ -0,0 +1,52 @@+name: transformers-compat-tests+category: Compatibility+version: 0.1+license: BSD3+cabal-version: >= 1.8+license-file: LICENSE+author: Edward A. Kmett+maintainer: Edward A. Kmett <ekmett@gmail.com>+stability: provisional+homepage: http://github.com/ekmett/transformers-compat/+bug-reports: http://github.com/ekmett/transformers-compat/issues+copyright: Copyright (C) 2012-2015 Edward A. Kmett+synopsis: transformers-compat tests+description: @transformers-copmat@ tests+build-type: Simple+tested-with: GHC == 7.0.4+ , GHC == 7.2.2+ , GHC == 7.4.2+ , GHC == 7.6.3+ , GHC == 7.8.4+ , GHC == 7.10.3+ , GHC == 8.0.2+ , GHC == 8.2.2+ , GHC == 8.4.1++source-repository head+ type: git+ location: git://github.com/ekmett/transformers-compat.git++flag tests+ default: True+ description: Enable the tests.++test-suite spec+ if !flag(tests)+ buildable: False++ type: exitcode-stdio-1.0+ main-is: Spec.hs+ other-modules: GenericsSpec+ GenericsTypes+ build-depends: base >= 4.3 && < 5+ , deriving-compat >= 0.3.4 && < 1+ , generic-deriving >= 1.10 && < 2+ , hspec >= 2 && < 3+ , QuickCheck >= 2 && < 3+ , tagged >= 0.7 && < 1+ , transformers >= 0.2 && < 0.6+ , transformers-compat+ build-tool-depends: hspec-discover:hspec-discover >= 2 && < 3+ hs-source-dirs: .+ ghc-options: -Wall -threaded -rtsopts
transformers-compat.cabal view
@@ -1,6 +1,6 @@ name: transformers-compat category: Compatibility-version: 0.6.0.6+version: 0.6.1.2 license: BSD3 cabal-version: >= 1.8 license-file: LICENSE@@ -38,6 +38,9 @@ .gitignore .vim.custom config+ tests/*.hs+ tests/LICENSE+ tests/transformers-compat-tests.cabal HLint.hs README.markdown CHANGELOG.markdown@@ -47,7 +50,7 @@ location: git://github.com/ekmett/transformers-compat.git flag two- default: False+ default: True description: Use transformers 0.2. This will be selected by cabal picking the appropriate version. manual: True @@ -100,7 +103,9 @@ if flag(four) cpp-options: -DTRANSFORMERS_FOUR hs-source-dirs: 0.5- build-depends: transformers >= 0.4 && < 0.5+ -- Don't allow transformers-0.4.0.0+ -- See https://github.com/ekmett/transformers-compat/issues/35+ build-depends: transformers >= 0.4.1 && < 0.5 else if flag(three) hs-source-dirs: 0.3 0.5@@ -144,7 +149,7 @@ Data.Functor.Classes Data.Functor.Sum - if flag(two) || flag(three) || flag(five)+ if flag(two) || flag(three) || flag(four) || flag(five) exposed-modules: Control.Monad.Trans.Accum Control.Monad.Trans.Select@@ -153,28 +158,3 @@ exposed-modules: Data.Functor.Classes.Generic Data.Functor.Classes.Generic.Internal--test-suite spec- if !impl(ghc >= 8.0) && !flag(generic-deriving)- buildable: False-- type: exitcode-stdio-1.0- main-is: Spec.hs- other-modules: GenericsSpec- GenericsTypes- build-depends: base >= 4.3 && < 5- , deriving-compat >= 0.3.4 && < 1- , hspec >= 2 && < 3- , QuickCheck >= 2 && < 3- , tagged >= 0.7 && < 1- , transformers >= 0.2 && < 0.6- , transformers-compat-- if !impl(ghc >= 8.0)- build-depends: generic-deriving >= 1.10 && < 2-- if flag(four)- cpp-options: -DTRANSFORMERS_FOUR-- hs-source-dirs: tests- ghc-options: -Wall -threaded -rtsopts