Convert to cabal.project
authorOleg Grenrus <oleg.grenrus@iki.fi>
Fri, 12 Apr 2019 21:16:03 +0000 (00:16 +0300)
committerDavid Feuer <David.Feuer@gmail.com>
Tue, 16 Apr 2019 19:53:41 +0000 (15:53 -0400)
- Move the lib into `containers`
- Move the tests and benchmarks into `containers-tests`
- Make some adjustments so -Whome-modules is happy
- `ln -s` stuff from `containers` to `containers-tests`
  so things work; use containers-tests to be the library under test and
  benchmarking

105 files changed:
.travis.yml
cabal.haskell-ci [new file with mode: 0644]
cabal.project [new file with mode: 0644]
containers-tests/LICENSE [new symlink]
containers-tests/benchmarks/.gitignore [moved from benchmarks/.gitignore with 100% similarity]
containers-tests/benchmarks/IntMap.hs [moved from benchmarks/IntMap.hs with 100% similarity]
containers-tests/benchmarks/IntSet.hs [moved from benchmarks/IntSet.hs with 100% similarity]
containers-tests/benchmarks/LookupGE/IntMap.hs [moved from benchmarks/LookupGE/IntMap.hs with 100% similarity]
containers-tests/benchmarks/LookupGE/LookupGE_IntMap.hs [moved from benchmarks/LookupGE/LookupGE_IntMap.hs with 100% similarity]
containers-tests/benchmarks/LookupGE/LookupGE_Map.hs [moved from benchmarks/LookupGE/LookupGE_Map.hs with 100% similarity]
containers-tests/benchmarks/LookupGE/Makefile [moved from benchmarks/LookupGE/Makefile with 100% similarity]
containers-tests/benchmarks/LookupGE/Map.hs [moved from benchmarks/LookupGE/Map.hs with 100% similarity]
containers-tests/benchmarks/Makefile [moved from benchmarks/Makefile with 100% similarity]
containers-tests/benchmarks/Map.hs [moved from benchmarks/Map.hs with 100% similarity]
containers-tests/benchmarks/Sequence.hs [moved from benchmarks/Sequence.hs with 99% similarity]
containers-tests/benchmarks/Set.hs [moved from benchmarks/Set.hs with 100% similarity]
containers-tests/benchmarks/SetOperations/Makefile [moved from benchmarks/SetOperations/Makefile with 100% similarity]
containers-tests/benchmarks/SetOperations/SetOperations-IntMap.hs [moved from benchmarks/SetOperations/SetOperations-IntMap.hs with 100% similarity]
containers-tests/benchmarks/SetOperations/SetOperations-IntSet.hs [moved from benchmarks/SetOperations/SetOperations-IntSet.hs with 100% similarity]
containers-tests/benchmarks/SetOperations/SetOperations-Map.hs [moved from benchmarks/SetOperations/SetOperations-Map.hs with 100% similarity]
containers-tests/benchmarks/SetOperations/SetOperations-Set.hs [moved from benchmarks/SetOperations/SetOperations-Set.hs with 100% similarity]
containers-tests/benchmarks/SetOperations/SetOperations.hs [moved from benchmarks/SetOperations/SetOperations.hs with 100% similarity]
containers-tests/benchmarks/bench-cmp.pl [moved from benchmarks/bench-cmp.pl with 100% similarity]
containers-tests/benchmarks/bench-cmp.sh [moved from benchmarks/bench-cmp.sh with 100% similarity]
containers-tests/containers-tests.cabal [new file with mode: 0644]
containers-tests/include [new symlink]
containers-tests/src [new symlink]
containers-tests/tests/IntMapValidity.hs [moved from tests/IntMapValidity.hs with 100% similarity]
containers-tests/tests/IntSetValidity.hs [moved from tests/IntSetValidity.hs with 100% similarity]
containers-tests/tests/Makefile [moved from tests/Makefile with 100% similarity]
containers-tests/tests/bitqueue-properties.hs [moved from tests/bitqueue-properties.hs with 100% similarity]
containers-tests/tests/intmap-properties.hs [moved from tests/intmap-properties.hs with 100% similarity]
containers-tests/tests/intmap-strictness.hs [moved from tests/intmap-strictness.hs with 100% similarity]
containers-tests/tests/intset-properties.hs [moved from tests/intset-properties.hs with 100% similarity]
containers-tests/tests/intset-strictness.hs [moved from tests/intset-strictness.hs with 100% similarity]
containers-tests/tests/listutils-properties.hs [moved from tests/listutils-properties.hs with 100% similarity]
containers-tests/tests/map-properties.hs [moved from tests/map-properties.hs with 100% similarity]
containers-tests/tests/map-strictness.hs [moved from tests/map-strictness.hs with 100% similarity]
containers-tests/tests/seq-properties.hs [moved from tests/seq-properties.hs with 100% similarity]
containers-tests/tests/set-properties.hs [moved from tests/set-properties.hs with 100% similarity]
containers-tests/tests/tree-properties.hs [moved from tests/tree-properties.hs with 100% similarity]
containers.cabal [deleted file]
containers/LICENSE [moved from LICENSE with 100% similarity]
containers/README.md [moved from README.md with 100% similarity]
containers/Setup.hs [moved from Setup.hs with 100% similarity]
containers/changelog.md [moved from changelog.md with 100% similarity]
containers/containers.cabal [new file with mode: 0644]
containers/docs/.gitignore [moved from docs/.gitignore with 100% similarity]
containers/docs/Makefile [moved from docs/Makefile with 100% similarity]
containers/docs/_extensions/hs-theme.py [moved from docs/_extensions/hs-theme.py with 100% similarity]
containers/docs/_static/css/hs-theme.css [moved from docs/_static/css/hs-theme.css with 100% similarity]
containers/docs/_static/images/favicon-16x16.png [moved from docs/_static/images/favicon-16x16.png with 100% similarity]
containers/docs/_static/images/favicon-green-16x16.png [moved from docs/_static/images/favicon-green-16x16.png with 100% similarity]
containers/docs/_static/images/haskell-logo-black.svg [moved from docs/_static/images/haskell-logo-black.svg with 100% similarity]
containers/docs/_static/images/haskell-logo-green.svg [moved from docs/_static/images/haskell-logo-green.svg with 100% similarity]
containers/docs/_static/sitemap.xml [moved from docs/_static/sitemap.xml with 100% similarity]
containers/docs/_templates/layout.html [moved from docs/_templates/layout.html with 100% similarity]
containers/docs/conf.py [moved from docs/conf.py with 100% similarity]
containers/docs/index.rst [moved from docs/index.rst with 100% similarity]
containers/docs/intro.rst [moved from docs/intro.rst with 100% similarity]
containers/docs/make.bat [moved from docs/make.bat with 100% similarity]
containers/docs/map.rst [moved from docs/map.rst with 100% similarity]
containers/docs/sequence.rst [moved from docs/sequence.rst with 100% similarity]
containers/docs/set.rst [moved from docs/set.rst with 100% similarity]
containers/include/containers.h [moved from include/containers.h with 100% similarity]
containers/prologue.txt [moved from prologue.txt with 100% similarity]
containers/src/Data/Containers/ListUtils.hs [moved from Data/Containers/ListUtils.hs with 100% similarity]
containers/src/Data/Graph.hs [moved from Data/Graph.hs with 100% similarity]
containers/src/Data/IntMap.hs [moved from Data/IntMap.hs with 100% similarity]
containers/src/Data/IntMap/Internal.hs [moved from Data/IntMap/Internal.hs with 100% similarity]
containers/src/Data/IntMap/Internal/Debug.hs [moved from Data/IntMap/Internal/Debug.hs with 100% similarity]
containers/src/Data/IntMap/Internal/DeprecatedDebug.hs [moved from Data/IntMap/Internal/DeprecatedDebug.hs with 100% similarity]
containers/src/Data/IntMap/Lazy.hs [moved from Data/IntMap/Lazy.hs with 100% similarity]
containers/src/Data/IntMap/Merge/Lazy.hs [moved from Data/IntMap/Merge/Lazy.hs with 100% similarity]
containers/src/Data/IntMap/Merge/Strict.hs [moved from Data/IntMap/Merge/Strict.hs with 100% similarity]
containers/src/Data/IntMap/Strict.hs [moved from Data/IntMap/Strict.hs with 100% similarity]
containers/src/Data/IntMap/Strict/Internal.hs [moved from Data/IntMap/Strict/Internal.hs with 100% similarity]
containers/src/Data/IntSet.hs [moved from Data/IntSet.hs with 100% similarity]
containers/src/Data/IntSet/Internal.hs [moved from Data/IntSet/Internal.hs with 100% similarity]
containers/src/Data/Map.hs [moved from Data/Map.hs with 100% similarity]
containers/src/Data/Map/Internal.hs [moved from Data/Map/Internal.hs with 100% similarity]
containers/src/Data/Map/Internal/Debug.hs [moved from Data/Map/Internal/Debug.hs with 100% similarity]
containers/src/Data/Map/Internal/DeprecatedShowTree.hs [moved from Data/Map/Internal/DeprecatedShowTree.hs with 100% similarity]
containers/src/Data/Map/Lazy.hs [moved from Data/Map/Lazy.hs with 100% similarity]
containers/src/Data/Map/Merge/Lazy.hs [moved from Data/Map/Merge/Lazy.hs with 100% similarity]
containers/src/Data/Map/Merge/Strict.hs [moved from Data/Map/Merge/Strict.hs with 100% similarity]
containers/src/Data/Map/Strict.hs [moved from Data/Map/Strict.hs with 100% similarity]
containers/src/Data/Map/Strict/Internal.hs [moved from Data/Map/Strict/Internal.hs with 100% similarity]
containers/src/Data/Sequence.hs [moved from Data/Sequence.hs with 100% similarity]
containers/src/Data/Sequence/Internal.hs [moved from Data/Sequence/Internal.hs with 100% similarity]
containers/src/Data/Sequence/Internal/Sorting.hs [moved from Data/Sequence/Internal/Sorting.hs with 100% similarity]
containers/src/Data/Sequence/Internal/sorting.md [moved from Data/Sequence/Internal/sorting.md with 100% similarity]
containers/src/Data/Set.hs [moved from Data/Set.hs with 100% similarity]
containers/src/Data/Set/Internal.hs [moved from Data/Set/Internal.hs with 100% similarity]
containers/src/Data/Tree.hs [moved from Data/Tree.hs with 100% similarity]
containers/src/Utils/Containers/Internal/BitQueue.hs [moved from Utils/Containers/Internal/BitQueue.hs with 100% similarity]
containers/src/Utils/Containers/Internal/BitUtil.hs [moved from Utils/Containers/Internal/BitUtil.hs with 100% similarity]
containers/src/Utils/Containers/Internal/Coercions.hs [moved from Utils/Containers/Internal/Coercions.hs with 100% similarity]
containers/src/Utils/Containers/Internal/PtrEquality.hs [moved from Utils/Containers/Internal/PtrEquality.hs with 100% similarity]
containers/src/Utils/Containers/Internal/State.hs [moved from Utils/Containers/Internal/State.hs with 100% similarity]
containers/src/Utils/Containers/Internal/StrictMaybe.hs [moved from Utils/Containers/Internal/StrictMaybe.hs with 100% similarity]
containers/src/Utils/Containers/Internal/StrictPair.hs [moved from Utils/Containers/Internal/StrictPair.hs with 100% similarity]
containers/src/Utils/Containers/Internal/TypeError.hs [moved from Utils/Containers/Internal/TypeError.hs with 100% similarity]
docs/_extensions/haddock-autolink [deleted submodule]
stack.yaml

index f9ae2d0..90f3aa8 100644 (file)
-# NB: don't set `language: haskell` here
-
-# See also https://github.com/hvr/multi-ghc-travis for more information
-env:
- - GHCVER=7.6.3 CABALVER=1.16
- - GHCVER=7.8.4 CABALVER=1.18
- - GHCVER=7.10.3 CABALVER=1.22
- - GHCVER=8.0.2 CABALVER=1.24
- - GHCVER=8.2.2 CABALVER=2.0
- - GHCVER=8.4.3 CABALVER=2.4
- - GHCVER=8.6.2 CABALVER=2.4
- - GHCVER=head CABALVER=head
-
+# This Travis job script has been generated by a script via
+#
+#   haskell-ci '--config=cabal.haskell-ci' 'cabal.project'
+#
+# For more information, see https://github.com/haskell-CI/haskell-ci
+#
+# version: 0.3.20190413
+#
+language: c
+dist: xenial
+git:
+  # whether to recursively clone submodules
+  submodules: false
+branches:
+  only:
+    - master
+cache:
+  directories:
+    - $HOME/.cabal/packages
+    - $HOME/.cabal/store
+before_cache:
+  - rm -fv $CABALHOME/packages/hackage.haskell.org/build-reports.log
+  # remove files that are regenerated by 'cabal update'
+  - rm -fv $CABALHOME/packages/hackage.haskell.org/00-index.*
+  - rm -fv $CABALHOME/packages/hackage.haskell.org/*.json
+  - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.cache
+  - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar
+  - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar.idx
+  - rm -rfv $CABALHOME/packages/head.hackage
 matrix:
-  allow_failures:
-   - env: GHCVER=head CABALVER=head
-
-# Note: the distinction between `before_install` and `install` is not
-#       important.
+  include:
+    - compiler: ghc-8.6.4
+      addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.6.4","cabal-install-2.4"]}}
+    - compiler: ghc-8.4.4
+      addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.4.4","cabal-install-2.4"]}}
+    - compiler: ghc-8.2.2
+      addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.2.2","cabal-install-2.4"]}}
+    - compiler: ghc-8.0.2
+      addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.0.2","cabal-install-2.4"]}}
+    - compiler: ghc-7.10.3
+      addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.10.3","cabal-install-2.4"]}}
+    - compiler: ghc-7.8.4
+      addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.8.4","cabal-install-2.4"]}}
+    - compiler: ghc-7.6.3
+      addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.6.3","cabal-install-2.4"]}}
 before_install:
- - travis_retry sudo add-apt-repository -y ppa:hvr/ghc
- - travis_retry sudo apt-get update
- - travis_retry sudo apt-get install cabal-install-$CABALVER ghc-$GHCVER
- - export PATH=/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:$PATH
- - cabal --version
-
+  - HC=$(echo "/opt/$CC/bin/ghc" | sed 's/-/\//')
+  - HCPKG="$HC-pkg"
+  - unset CC
+  - CABAL=/opt/ghc/bin/cabal
+  - CABALHOME=$HOME/.cabal
+  - export PATH="$CABALHOME/bin:$PATH"
+  - TOP=$(pwd)
+  - HCNUMVER=$(( $(${HC} --numeric-version|sed -E 's/([0-9]+)\.([0-9]+)\.([0-9]+).*/\1 * 10000 + \2 * 100 + \3/') ))
+  - echo $HCNUMVER
+  - CABAL="$CABAL -vnormal+nowrap+markoutput"
+  - set -o pipefail
+  - |
+    echo 'function blue(s) { printf "\033[0;34m" s "\033[0m " }'           >> .colorful.awk
+    echo 'BEGIN { state = "output"; }'                                     >> .colorful.awk
+    echo '/^-----BEGIN CABAL OUTPUT-----$/ { state = "cabal" }'            >> .colorful.awk
+    echo '/^-----END CABAL OUTPUT-----$/ { state = "output" }'             >> .colorful.awk
+    echo '!/^(-----BEGIN CABAL OUTPUT-----|-----END CABAL OUTPUT-----)/ {' >> .colorful.awk
+    echo '  if (state == "cabal") {'                                       >> .colorful.awk
+    echo '    print blue($0)'                                              >> .colorful.awk
+    echo '  } else {'                                                      >> .colorful.awk
+    echo '    print $0'                                                    >> .colorful.awk
+    echo '  }'                                                             >> .colorful.awk
+    echo '}'                                                               >> .colorful.awk
+  - cat .colorful.awk
+  - |
+    color_cabal_output () {
+      awk -f $TOP/.colorful.awk
+    }
+  - echo text | color_cabal_output
 install:
- - travis_retry cabal update
- - cabal install --only-dependencies
- # we need to install the test-suite and benchmark deps manually as the cabal
- # solver would otherwise complain about cyclic deps
- - cabal install 'test-framework >= 0.3.3' 'test-framework-quickcheck2 >= 0.2.9' 'QuickCheck >= 2.7.1' 'ChasingBottoms' 'HUnit' 'test-framework-hunit'
-
- # If we enable benchmarks, we'll need 'criterion >= 0.4.0 && < 1.2'
-
-# Here starts the actual work to be performed for the package under
-# test; any command which exits with a non-zero exit code causes the
-# build to fail.
+  - ${CABAL} --version
+  - echo "$(${HC} --version) [$(${HC} --print-project-git-commit-id 2> /dev/null || echo '?')]"
+  - TEST=--enable-tests
+  - BENCH=--enable-benchmarks
+  - if [ $HCNUMVER -lt 70804 ] ; then BENCH=--disable-benchmarks ; fi
+  - GHCHEAD=${GHCHEAD-false}
+  - rm -f $CABALHOME/config
+  - |
+    echo "verbose: normal +nowrap +markoutput"          >> $CABALHOME/config
+    echo "remote-build-reporting: anonymous"            >> $CABALHOME/config
+    echo "remote-repo-cache: $CABALHOME/packages"       >> $CABALHOME/config
+    echo "logs-dir:          $CABALHOME/logs"           >> $CABALHOME/config
+    echo "world-file:        $CABALHOME/world"          >> $CABALHOME/config
+    echo "extra-prog-path:   $CABALHOME/bin"            >> $CABALHOME/config
+    echo "symlink-bindir:    $CABALHOME/bin"            >> $CABALHOME/config
+    echo "build-summary:     $CABALHOME/logs/build.log" >> $CABALHOME/config
+    echo "store-dir:         $CABALHOME/store"          >> $CABALHOME/config
+    echo "install-dirs user"                            >> $CABALHOME/config
+    echo "  prefix: $CABALHOME"                         >> $CABALHOME/config
+    echo "repository hackage.haskell.org"               >> $CABALHOME/config
+    echo "  url: http://hackage.haskell.org/"           >> $CABALHOME/config
+  - cat $CABALHOME/config
+  - rm -fv cabal.project cabal.project.local cabal.project.freeze
+  - travis_retry ${CABAL} v2-update -v
+  # Generate cabal.project
+  - rm -rf cabal.project cabal.project.local cabal.project.freeze
+  - touch cabal.project
+  - |
+    echo 'packages: "containers"' >> cabal.project
+    echo 'packages: "containers-tests"' >> cabal.project
+  - |
+    echo "write-ghc-environment-files: always" >> cabal.project
+  - "for pkg in $($HCPKG list --simple-output); do echo $pkg | sed 's/-[^-]*$//' | grep -vE -- '^(binary|containers|containers-tests)$' | sed 's/^/constraints: /' | sed 's/$/ installed/' >> cabal.project.local; done"
+  - cat cabal.project || true
+  - cat cabal.project.local || true
+  - if [ -f "containers/configure.ac" ]; then (cd "containers" && autoreconf -i); fi
+  - if [ -f "containers-tests/configure.ac" ]; then (cd "containers-tests" && autoreconf -i); fi
+  - ${CABAL} v2-freeze -w ${HC} ${TEST} ${BENCH} | color_cabal_output
+  - "cat cabal.project.freeze | sed -E 's/^(constraints: *| *)//' | sed 's/any.//'"
+  - rm  cabal.project.freeze
 script:
- # -v2 provides useful information for debugging
- - cabal configure -v2 --enable-tests
-
- # We'd like to
- # --enable-benchmarks
- # but CI time goes through the roof. Maybe there's a way to limit it to just one GHC version?
-
- # this builds all libraries and executables
- # (including tests/benchmarks)
- - cabal build
- - cabal test
-
- # tests that a source-distribution can be generated
- - cabal sdist
-
- # check that the generated source-distribution can be built & installed
- - export SRC_TGZ=$(cabal info . | awk '{print $2 ".tar.gz";exit}') ;
-   cd dist/;
-   if [ -f "$SRC_TGZ" ]; then
-      cabal install --force-reinstalls "$SRC_TGZ";
-   else
-      echo "expected '$SRC_TGZ' not found";
-      exit 1;
-   fi
+  - DISTDIR=$(mktemp -d /tmp/dist-test.XXXX)
+  # Packaging...
+  - ${CABAL} v2-sdist all | color_cabal_output
+  # Unpacking...
+  - mv dist-newstyle/sdist/*.tar.gz ${DISTDIR}/
+  - cd ${DISTDIR} || false
+  - find . -maxdepth 1 -name '*.tar.gz' -exec tar -xvf '{}' \;
+  # Generate cabal.project
+  - rm -rf cabal.project cabal.project.local cabal.project.freeze
+  - touch cabal.project
+  - |
+    echo 'packages: "containers-*/*.cabal"' >> cabal.project
+    echo 'packages: "containers-tests-*/*.cabal"' >> cabal.project
+  - |
+    echo "write-ghc-environment-files: always" >> cabal.project
+  - "for pkg in $($HCPKG list --simple-output); do echo $pkg | sed 's/-[^-]*$//' | grep -vE -- '^(binary|containers|containers-tests)$' | sed 's/^/constraints: /' | sed 's/$/ installed/' >> cabal.project.local; done"
+  - cat cabal.project || true
+  - cat cabal.project.local || true
+  # Building...
+  # this builds all libraries and executables (without tests/benchmarks)
+  - ${CABAL} v2-build -w ${HC} --disable-tests --disable-benchmarks all | color_cabal_output
+  # Building with tests and benchmarks...
+  # build & run tests, build benchmarks
+  - ${CABAL} v2-build -w ${HC} ${TEST} ${BENCH} all | color_cabal_output
+  # Testing...
+  - ${CABAL} v2-test -w ${HC} ${TEST} ${BENCH} all | color_cabal_output
+  # cabal check...
+  - (cd containers-* && ${CABAL} -vnormal check)
+  - (cd containers-tests-* && ${CABAL} -vnormal check)
+  # haddock...
+  - ${CABAL} v2-haddock -w ${HC} ${TEST} ${BENCH} all | color_cabal_output
+  # Building without installed constraints for packages in global-db...
+  - rm -f cabal.project.local
+  - ${CABAL} v2-build -w ${HC} --disable-tests --disable-benchmarks all | color_cabal_output
 
+# REGENDATA ["--config=cabal.haskell-ci","cabal.project"]
 # EOF
diff --git a/cabal.haskell-ci b/cabal.haskell-ci
new file mode 100644 (file)
index 0000000..5d514b3
--- /dev/null
@@ -0,0 +1,14 @@
+-- configuration for haskell-ci
+-- so we don't need to pass all via command line arguments
+
+-- build only master branch, or PRs to master branch
+branches: master
+
+-- don't install --dep as cabal doesn't handle it for this project
+install-dependencies: False
+
+-- on GHC-7.10.3 we need to reinstall binary?
+installed: +all -binary
+
+-- gauge works only with newer GHC
+benchmarks: >=7.8.4
diff --git a/cabal.project b/cabal.project
new file mode 100644 (file)
index 0000000..257339c
--- /dev/null
@@ -0,0 +1,9 @@
+packages:
+  containers/
+  containers-tests/
+
+tests: True
+benchmarks: True
+
+-- package containers-tests
+--   ghc-options: -Werror
diff --git a/containers-tests/LICENSE b/containers-tests/LICENSE
new file mode 120000 (symlink)
index 0000000..2f5f400
--- /dev/null
@@ -0,0 +1 @@
+../containers/LICENSE
\ No newline at end of file
similarity index 99%
rename from benchmarks/Sequence.hs
rename to containers-tests/benchmarks/Sequence.hs
index 27b802b..261e8dc 100644 (file)
@@ -8,7 +8,7 @@ import Gauge (bench, bgroup, defaultMain, nf)
 import Data.Foldable (foldl', foldr')
 import qualified Data.Sequence as S
 import qualified Data.Foldable
-import Data.Traversable (traverse)
+import Data.Traversable (traverse, sequenceA)
 import System.Random (mkStdGen, randoms)
 
 main = do
diff --git a/containers-tests/containers-tests.cabal b/containers-tests/containers-tests.cabal
new file mode 100644 (file)
index 0000000..8babc35
--- /dev/null
@@ -0,0 +1,500 @@
+name:               containers-tests
+version:            0
+license:            BSD3
+license-file:       LICENSE
+maintainer:         libraries@haskell.org
+bug-reports:        https://github.com/haskell/containers/issues
+synopsis:           Assorted concrete container types: Tests
+category:           Data Structures
+description:
+  .
+  This package contains tests and benchmarks for @containers-package
+
+build-type:         Simple
+cabal-version:      >=1.8
+extra-source-files:
+  include/containers.h
+  tests/Makefile
+  tests/*.hs
+  benchmarks/Makefile
+  benchmarks/bench-cmp.pl
+  benchmarks/bench-cmp.sh
+  benchmarks/*.hs
+  benchmarks/SetOperations/Makefile
+  benchmarks/SetOperations/*.hs
+  benchmarks/LookupGE/Makefile
+  benchmarks/LookupGE/*.hs
+
+tested-with:
+  GHC ==7.6.3 || ==7.8.4 || ==7.10.3 || ==8.0.2 || ==8.2.2 || ==8.4.4 || ==8.6.4
+
+source-repository head
+  type:     git
+  location: http://github.com/haskell/containers.git
+
+-- Copy of containers library,
+library
+  -- this is important for testing; may it affect benchmarks?
+  cpp-options:      -DTESTING
+  build-depends:
+      array    >=0.4.0.0
+    , base     >=4.6     && <5
+    , deepseq  >=1.2     && <1.5
+
+  include-dirs:     include
+  hs-source-dirs:   src
+  ghc-options:      -O2 -Wall
+  other-extensions:
+    BangPatterns
+    CPP
+
+  exposed-modules:
+    Data.Containers.ListUtils
+    Data.Graph
+    Data.IntMap
+    Data.IntMap.Internal
+    Data.IntMap.Internal.Debug
+    Data.IntMap.Lazy
+    Data.IntMap.Merge.Lazy
+    Data.IntMap.Merge.Strict
+    Data.IntMap.Strict
+    Data.IntMap.Strict.Internal
+    Data.IntSet
+    Data.IntSet.Internal
+    Data.Map
+    Data.Map.Internal
+    Data.Map.Internal.Debug
+    Data.Map.Lazy
+    Data.Map.Merge.Lazy
+    Data.Map.Merge.Strict
+    Data.Map.Strict
+    Data.Map.Strict.Internal
+    Data.Sequence
+    Data.Sequence.Internal
+    Data.Sequence.Internal.Sorting
+    Data.Set
+    Data.Set.Internal
+    Data.Tree
+    Utils.Containers.Internal.BitQueue
+    Utils.Containers.Internal.BitUtil
+    Utils.Containers.Internal.StrictPair
+
+  other-modules:
+    Utils.Containers.Internal.Coercions
+    Utils.Containers.Internal.PtrEquality
+    Utils.Containers.Internal.State
+    Utils.Containers.Internal.StrictMaybe
+
+  if impl(ghc)
+    other-modules:
+      Data.IntMap.Internal.DeprecatedDebug
+      Data.Map.Internal.DeprecatedShowTree
+      Utils.Containers.Internal.TypeError
+
+-----------------------------
+-- B E N C H M A R K I N G --
+-----------------------------
+
+benchmark intmap-benchmarks
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks
+  main-is:        IntMap.hs
+  ghc-options:    -O2
+  build-depends:
+      base              >=4.6     && <5
+    , containers-tests
+    , deepseq           >=1.1.0.0 && <1.5
+    , gauge             >=0.2.3   && <0.3
+
+benchmark intset-benchmarks
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks
+  main-is:        IntSet.hs
+  ghc-options:    -O2
+  build-depends:
+      base              >=4.6     && <5
+    , containers-tests
+    , deepseq           >=1.1.0.0 && <1.5
+    , gauge             >=0.2.3   && <0.3
+
+benchmark map-benchmarks
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks
+  main-is:        Map.hs
+  ghc-options:    -O2
+  build-depends:
+      base              >=4.6     && <5
+    , containers-tests
+    , deepseq           >=1.1.0.0 && <1.5
+    , gauge             >=0.2.3   && <0.3
+    , transformers
+
+benchmark sequence-benchmarks
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks
+  main-is:        Sequence.hs
+  ghc-options:    -O2
+  build-depends:
+      base              >=4.6     && <5
+    , containers-tests
+    , deepseq           >=1.1.0.0 && <1.5
+    , gauge             >=0.2.3   && <0.3
+    , random            >=0       && <1.2
+    , transformers
+
+benchmark set-benchmarks
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks
+  main-is:        Set.hs
+  ghc-options:    -O2
+  build-depends:
+      base              >=4.6     && <5
+    , containers-tests
+    , deepseq           >=1.1.0.0 && <1.5
+    , gauge             >=0.2.3   && <0.3
+
+benchmark set-operations-intmap
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks/SetOperations
+  main-is:        SetOperations-IntMap.hs
+  other-modules:  SetOperations
+  ghc-options:    -O2
+  build-depends:
+      base              >=4.6   && <5
+    , containers-tests
+    , gauge             >=0.2.3 && <0.3
+
+benchmark set-operations-intset
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks/SetOperations
+  main-is:        SetOperations-IntSet.hs
+  other-modules:  SetOperations
+  ghc-options:    -O2
+  build-depends:
+      base              >=4.6   && <5
+    , containers-tests
+    , gauge             >=0.2.3 && <0.3
+
+benchmark set-operations-map
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks/SetOperations
+  main-is:        SetOperations-Map.hs
+  other-modules:  SetOperations
+  ghc-options:    -O2
+  build-depends:
+      base              >=4.6   && <5
+    , containers-tests
+    , gauge             >=0.2.3 && <0.3
+
+benchmark set-operations-set
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks/SetOperations
+  main-is:        SetOperations-Set.hs
+  other-modules:  SetOperations
+  ghc-options:    -O2
+  build-depends:
+      base              >=4.6   && <5
+    , containers-tests
+    , gauge             >=0.2.3 && <0.3
+
+benchmark lookupge-intmap
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks/LookupGE
+  main-is:        IntMap.hs
+  other-modules:  LookupGE_IntMap
+  build-depends:  containers-tests
+  build-depends:
+      base     >=4.6     && <5
+    , deepseq  >=1.1.0.0 && <1.5
+    , gauge    >=0.2.3   && <0.3
+
+benchmark lookupge-map
+  type:           exitcode-stdio-1.0
+  hs-source-dirs: benchmarks/LookupGE
+  main-is:        Map.hs
+  other-modules:  LookupGE_Map
+  build-depends:  containers-tests
+  ghc-options:    -O2
+  build-depends:
+      base     >=4.6     && <5
+    , deepseq  >=1.1.0.0 && <1.5
+    , gauge    >=0.2.3   && <0.3
+
+-------------------
+-- T E S T I N G --
+-------------------
+
+-- Every test-suite contains the build-depends and options of the library,
+-- plus the testing stuff.
+
+test-suite map-lazy-properties
+  hs-source-dirs:   tests
+  main-is:          map-properties.hs
+  type:             exitcode-stdio-1.0
+  build-depends:    containers-tests
+  build-depends:
+      array    >=0.4.0.0
+    , base     >=4.6     && <5
+    , deepseq  >=1.2     && <1.5
+
+  ghc-options:      -O2
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:
+      HUnit
+    , QuickCheck                  >=2.7.1
+    , test-framework
+    , test-framework-hunit
+    , test-framework-quickcheck2
+    , transformers
+
+test-suite map-strict-properties
+  hs-source-dirs:   tests
+  main-is:          map-properties.hs
+  type:             exitcode-stdio-1.0
+  build-depends:    containers-tests
+  build-depends:
+      array    >=0.4.0.0
+    , base     >=4.6     && <5
+    , deepseq  >=1.2     && <1.5
+
+  ghc-options:      -O2
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:
+      HUnit
+    , QuickCheck                  >=2.7.1
+    , test-framework
+    , test-framework-hunit
+    , test-framework-quickcheck2
+    , transformers
+
+test-suite bitqueue-properties
+  hs-source-dirs:   tests
+  main-is:          bitqueue-properties.hs
+  type:             exitcode-stdio-1.0
+  build-depends:    base >=4.6 && <5
+  ghc-options:      -O2
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:    containers-tests
+  build-depends:
+      QuickCheck                  >=2.7.1
+    , test-framework
+    , test-framework-quickcheck2
+
+test-suite set-properties
+  hs-source-dirs:   tests
+  main-is:          set-properties.hs
+  type:             exitcode-stdio-1.0
+  build-depends:
+      array    >=0.4.0.0
+    , base     >=4.6     && <5
+    , deepseq  >=1.2     && <1.5
+
+  ghc-options:      -O2
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:    containers-tests
+  build-depends:
+      HUnit
+    , QuickCheck                  >=2.7.1
+    , test-framework
+    , test-framework-hunit
+    , test-framework-quickcheck2
+    , transformers
+
+test-suite intmap-lazy-properties
+  hs-source-dirs:   tests
+  main-is:          intmap-properties.hs
+  type:             exitcode-stdio-1.0
+  other-modules:    IntMapValidity
+  build-depends:    containers-tests
+  build-depends:
+      array    >=0.4.0.0
+    , base     >=4.6     && <5
+    , deepseq  >=1.2     && <1.5
+
+  ghc-options:      -O2
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:
+      HUnit
+    , QuickCheck                  >=2.7.1
+    , test-framework
+    , test-framework-hunit
+    , test-framework-quickcheck2
+
+test-suite intmap-strict-properties
+  hs-source-dirs:   tests
+  main-is:          intmap-properties.hs
+  type:             exitcode-stdio-1.0
+  cpp-options:      -DSTRICT
+  other-modules:    IntMapValidity
+  build-depends:    containers-tests
+  build-depends:
+      array    >=0.4.0.0
+    , base     >=4.6     && <5
+    , deepseq  >=1.2     && <1.5
+
+  ghc-options:      -O2
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:    containers-tests
+  build-depends:
+      HUnit
+    , QuickCheck                  >=2.7.1
+    , test-framework
+    , test-framework-hunit
+    , test-framework-quickcheck2
+
+test-suite intset-properties
+  hs-source-dirs:   tests
+  main-is:          intset-properties.hs
+  type:             exitcode-stdio-1.0
+  other-modules:    IntSetValidity
+  build-depends:
+      array    >=0.4.0.0
+    , base     >=4.6     && <5
+    , deepseq  >=1.2     && <1.5
+
+  ghc-options:      -O2
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:    containers-tests
+  build-depends:
+      HUnit
+    , QuickCheck                  >=2.7.1
+    , test-framework
+    , test-framework-hunit
+    , test-framework-quickcheck2
+
+test-suite seq-properties
+  hs-source-dirs:   tests
+  main-is:          seq-properties.hs
+  type:             exitcode-stdio-1.0
+  build-depends:    containers-tests
+  build-depends:
+      array    >=0.4.0.0
+    , base     >=4.6     && <5
+    , deepseq  >=1.2     && <1.5
+
+  ghc-options:      -O2
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:
+      QuickCheck                  >=2.7.1
+    , test-framework
+    , test-framework-quickcheck2
+    , transformers
+
+test-suite tree-properties
+  hs-source-dirs:   tests
+  main-is:          tree-properties.hs
+  type:             exitcode-stdio-1.0
+  build-depends:    containers-tests
+  build-depends:
+      array    >=0.4.0.0
+    , base     >=4.6     && <5
+    , deepseq  >=1.2     && <1.5
+
+  ghc-options:      -O2
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:
+      QuickCheck                  >=2.7.1
+    , test-framework
+    , test-framework-quickcheck2
+    , transformers
+
+test-suite map-strictness-properties
+  hs-source-dirs:   tests
+  main-is:          map-strictness.hs
+  type:             exitcode-stdio-1.0
+  build-depends:    containers-tests
+  build-depends:
+      array                       >=0.4.0.0
+    , base                        >=4.6     && <5
+    , ChasingBottoms
+    , deepseq                     >=1.2     && <1.5
+    , QuickCheck                  >=2.7.1
+    , test-framework              >=0.3.3
+    , test-framework-quickcheck2  >=0.2.9
+
+  ghc-options:      -Wall
+  other-extensions:
+    BangPatterns
+    CPP
+
+test-suite intmap-strictness-properties
+  hs-source-dirs:   tests
+  main-is:          intmap-strictness.hs
+  type:             exitcode-stdio-1.0
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:    containers-tests
+  build-depends:
+      array                       >=0.4.0.0
+    , base                        >=4.6     && <5
+    , ChasingBottoms
+    , deepseq                     >=1.2     && <1.5
+    , QuickCheck                  >=2.7.1
+    , test-framework              >=0.3.3
+    , test-framework-quickcheck2  >=0.2.9
+
+  ghc-options:      -Wall
+
+test-suite intset-strictness-properties
+  hs-source-dirs:   tests
+  main-is:          intset-strictness.hs
+  type:             exitcode-stdio-1.0
+  other-extensions:
+    BangPatterns
+    CPP
+
+  build-depends:    containers-tests
+  build-depends:
+      array                       >=0.4.0.0
+    , base                        >=4.6     && <5
+    , ChasingBottoms
+    , deepseq                     >=1.2     && <1.5
+    , QuickCheck                  >=2.7.1
+    , test-framework              >=0.3.3
+    , test-framework-quickcheck2  >=0.2.9
+
+  ghc-options:      -Wall
+
+test-suite listutils-properties
+  hs-source-dirs: tests
+  main-is:        listutils-properties.hs
+  type:           exitcode-stdio-1.0
+  build-depends:  containers-tests
+  build-depends:
+      base                        >=4.6   && <5
+    , ChasingBottoms
+    , deepseq                     >=1.2   && <1.5
+    , QuickCheck                  >=2.7.1
+    , test-framework              >=0.3.3
+    , test-framework-quickcheck2  >=0.2.9
+
+  ghc-options:    -Wall
diff --git a/containers-tests/include b/containers-tests/include
new file mode 120000 (symlink)
index 0000000..cc46bc8
--- /dev/null
@@ -0,0 +1 @@
+../containers/include
\ No newline at end of file
diff --git a/containers-tests/src b/containers-tests/src
new file mode 120000 (symlink)
index 0000000..17d939c
--- /dev/null
@@ -0,0 +1 @@
+../containers/src
\ No newline at end of file
diff --git a/containers.cabal b/containers.cabal
deleted file mode 100644 (file)
index f8be122..0000000
+++ /dev/null
@@ -1,605 +0,0 @@
-name: containers
-version: 0.6.0.1
-license: BSD3
-license-file: LICENSE
-maintainer: libraries@haskell.org
-bug-reports: https://github.com/haskell/containers/issues
-synopsis: Assorted concrete container types
-category: Data Structures
-description:
-    .
-    This package contains efficient general-purpose implementations
-    of various immutable container types including sets, maps, sequences,
-    trees, and graphs.
-    .
-    For a walkthrough of what this package provides with examples of common
-    operations see the [containers
-    introduction](https://haskell-containers.readthedocs.io).
-    .
-    The declared cost of each operation is either worst-case or amortized, but
-    remains valid even if structures are shared.
-
-build-type: Simple
-cabal-version:  >=1.8
-extra-source-files:
-    include/containers.h
-    tests/Makefile
-    tests/*.hs
-    benchmarks/Makefile
-    benchmarks/bench-cmp.pl
-    benchmarks/bench-cmp.sh
-    benchmarks/*.hs
-    benchmarks/SetOperations/Makefile
-    benchmarks/SetOperations/*.hs
-    benchmarks/LookupGE/Makefile
-    benchmarks/LookupGE/*.hs
-    changelog.md
-
-source-repository head
-    type:     git
-    location: http://github.com/haskell/containers.git
-
-Library
-    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
-
-    ghc-options: -O2 -Wall
-
-    other-extensions: CPP, BangPatterns
-
-    exposed-modules:
-        Data.Containers.ListUtils
-        Data.IntMap
-        Data.IntMap.Lazy
-        Data.IntMap.Strict
-        Data.IntMap.Strict.Internal
-        Data.IntMap.Internal
-        Data.IntMap.Internal.Debug
-        Data.IntMap.Merge.Lazy
-        Data.IntMap.Merge.Strict
-        Data.IntSet.Internal
-        Data.IntSet
-        Data.Map
-        Data.Map.Lazy
-        Data.Map.Merge.Lazy
-        Data.Map.Strict.Internal
-        Data.Map.Strict
-        Data.Map.Merge.Strict
-        Data.Map.Internal
-        Data.Map.Internal.Debug
-        Data.Set.Internal
-        Data.Set
-        Data.Graph
-        Data.Sequence
-        Data.Sequence.Internal
-        Data.Sequence.Internal.Sorting
-        Data.Tree
-        Utils.Containers.Internal.BitUtil
-        Utils.Containers.Internal.BitQueue
-        Utils.Containers.Internal.StrictPair
-
-    other-modules:
-        Utils.Containers.Internal.State
-        Utils.Containers.Internal.StrictMaybe
-        Utils.Containers.Internal.PtrEquality
-        Utils.Containers.Internal.Coercions
-    if impl(ghc)
-      other-modules:
-        Utils.Containers.Internal.TypeError
-        Data.Map.Internal.DeprecatedShowTree
-        Data.IntMap.Internal.DeprecatedDebug
-
-    include-dirs: include
-
------------------------------
--- B E N C H M A R K I N G --
------------------------------
-
-benchmark intmap-benchmarks
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks
-  main-is: IntMap.hs
-  ghc-options: -O2
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3,
-    deepseq >= 1.1.0.0 && < 1.5
-
-benchmark intset-benchmarks
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks
-  main-is: IntSet.hs
-  ghc-options: -O2
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3,
-    deepseq >= 1.1.0.0 && < 1.5
-
-benchmark map-benchmarks
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks
-  main-is: Map.hs
-  ghc-options: -O2
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3,
-    deepseq >= 1.1.0.0 && < 1.5,
-    transformers
-
-benchmark sequence-benchmarks
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks
-  main-is: Sequence.hs
-  ghc-options: -O2
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3,
-    deepseq >= 1.1.0.0 && < 1.5,
-    random < 1.2,
-    transformers
-
-benchmark set-benchmarks
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks
-  main-is: Set.hs
-  ghc-options: -O2
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3,
-    deepseq >= 1.1.0.0 && < 1.5
-
-benchmark set-operations-intmap
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks/SetOperations
-  main-is: SetOperations-IntMap.hs
-  other-modules: SetOperations
-  ghc-options: -O2
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3
-
-benchmark set-operations-intset
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks/SetOperations
-  main-is: SetOperations-IntSet.hs
-  other-modules: SetOperations
-  ghc-options: -O2
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3
-
-benchmark set-operations-map
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks/SetOperations
-  main-is: SetOperations-Map.hs
-  other-modules: SetOperations
-  ghc-options: -O2
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3
-
-benchmark set-operations-set
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks/SetOperations
-  main-is: SetOperations-Set.hs
-  other-modules: SetOperations
-  ghc-options: -O2
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3
-
-benchmark lookupge-intmap
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks/LookupGE, .
-  main-is: IntMap.hs
-  other-modules:
-      Data.IntMap
-      Data.IntMap.Internal.DeprecatedDebug
-      Data.IntMap.Lazy
-      Data.IntMap.Strict
-      Data.IntMap.Strict.Internal
-      Data.IntSet.Internal
-      LookupGE_IntMap
-      Utils.Containers.Internal.BitUtil
-      Utils.Containers.Internal.StrictPair
-      Utils.Containers.Internal.TypeError
-  ghc-options: -O2
-  cpp-options: -DTESTING
-  other-modules:
-    Data.IntMap.Internal
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3,
-    deepseq >= 1.1.0.0 && < 1.5
-
-benchmark lookupge-map
-  type: exitcode-stdio-1.0
-  hs-source-dirs: benchmarks/LookupGE, .
-  main-is: Map.hs
-  other-modules:
-      Data.Map
-      Data.Map.Internal.Debug
-      Data.Map.Internal.DeprecatedShowTree
-      Data.Map.Lazy
-      Data.Map.Strict
-      Data.Map.Strict.Internal
-      Data.Set.Internal
-      LookupGE_Map
-      Utils.Containers.Internal.BitQueue
-      Utils.Containers.Internal.BitUtil
-      Utils.Containers.Internal.PtrEquality
-      Utils.Containers.Internal.StrictMaybe
-      Utils.Containers.Internal.StrictPair
-  ghc-options: -O2
-  cpp-options: -DTESTING
-  other-modules:
-    Data.Map.Internal
-  build-depends:
-    base >= 4.6 && < 5,
-    containers,
-    gauge >= 0.2.3 && < 0.3,
-    deepseq >= 1.1.0.0 && < 1.5
-
--------------------
--- T E S T I N G --
--------------------
-
--- Every test-suite contains the build-depends and options of the library,
--- plus the testing stuff.
-
-Test-suite map-lazy-properties
-    hs-source-dirs: tests, .
-    main-is: map-properties.hs
-    other-modules:
-        Data.Map.Internal
-        Data.Map.Internal.Debug
-        Data.Map.Internal.DeprecatedShowTree
-        Data.Map.Lazy
-        Data.Map.Merge.Lazy
-        Data.Set
-        Data.Set.Internal
-        Utils.Containers.Internal.BitQueue
-        Utils.Containers.Internal.BitUtil
-        Utils.Containers.Internal.PtrEquality
-        Utils.Containers.Internal.StrictMaybe
-        Utils.Containers.Internal.StrictPair
-        Utils.Containers.Internal.TypeError
-    type: exitcode-stdio-1.0
-    cpp-options: -DTESTING
-
-    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
-    ghc-options: -O2
-    other-extensions: CPP, BangPatterns
-    include-dirs: include
-
-    build-depends:
-        HUnit,
-        QuickCheck >= 2.7.1,
-        test-framework,
-        test-framework-hunit,
-        test-framework-quickcheck2,
-        transformers
-
-Test-suite map-strict-properties
-    hs-source-dirs: tests, .
-    main-is: map-properties.hs
-    other-modules:
-        Data.Map.Internal
-        Data.Map.Internal.Debug
-        Data.Map.Internal.DeprecatedShowTree
-        Data.Map.Merge.Strict
-        Data.Map.Strict
-        Data.Map.Strict.Internal
-        Data.Set
-        Data.Set.Internal
-        Utils.Containers.Internal.BitQueue
-        Utils.Containers.Internal.BitUtil
-        Utils.Containers.Internal.PtrEquality
-        Utils.Containers.Internal.StrictMaybe
-        Utils.Containers.Internal.StrictPair
-        Utils.Containers.Internal.TypeError
-    type: exitcode-stdio-1.0
-    cpp-options: -DTESTING -DSTRICT
-
-    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
-    ghc-options: -O2
-    other-extensions: CPP, BangPatterns
-    include-dirs: include
-
-    build-depends:
-        HUnit,
-        QuickCheck >= 2.7.1,
-        test-framework,
-        test-framework-hunit,
-        test-framework-quickcheck2,
-        transformers
-
-Test-suite bitqueue-properties
-    hs-source-dirs: tests, .
-    main-is: bitqueue-properties.hs
-    other-modules:
-        Utils.Containers.Internal.BitQueue
-        Utils.Containers.Internal.BitUtil
-    type: exitcode-stdio-1.0
-    cpp-options: -DTESTING
-
-    build-depends: base >= 4.6 && < 5
-    ghc-options: -O2
-    other-extensions: CPP, BangPatterns
-    include-dirs: include
-
-    build-depends:
-        QuickCheck >= 2.7.1,
-        test-framework,
-        test-framework-quickcheck2
-
-Test-suite set-properties
-    hs-source-dirs: tests, .
-    main-is: set-properties.hs
-    other-modules:
-        Data.IntSet
-        Data.IntSet.Internal
-        Data.Set
-        Data.Set.Internal
-        Utils.Containers.Internal.BitUtil
-        Utils.Containers.Internal.PtrEquality
-        Utils.Containers.Internal.StrictPair
-    type: exitcode-stdio-1.0
-    cpp-options: -DTESTING
-
-    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
-    ghc-options: -O2
-    other-extensions: CPP, BangPatterns
-    include-dirs: include
-
-    build-depends:
-        HUnit,
-        QuickCheck >= 2.7.1,
-        test-framework,
-        test-framework-hunit,
-        test-framework-quickcheck2,
-        transformers
-
-Test-suite intmap-lazy-properties
-    hs-source-dirs: tests, .
-    main-is: intmap-properties.hs
-    other-modules:
-        Data.IntMap.Internal
-        Data.IntMap.Internal.Debug
-        Data.IntMap.Internal.DeprecatedDebug
-        Data.IntMap.Lazy
-        Data.IntSet
-        Data.IntSet.Internal
-        IntMapValidity
-        Utils.Containers.Internal.BitUtil
-        Utils.Containers.Internal.StrictPair
-        Utils.Containers.Internal.TypeError
-    type: exitcode-stdio-1.0
-    cpp-options: -DTESTING
-
-    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
-    ghc-options: -O2
-    other-extensions: CPP, BangPatterns
-    include-dirs: include
-
-    build-depends:
-        HUnit,
-        QuickCheck >= 2.7.1,
-        test-framework,
-        test-framework-hunit,
-        test-framework-quickcheck2
-
-Test-suite intmap-strict-properties
-    hs-source-dirs: tests, .
-    main-is: intmap-properties.hs
-    other-modules:
-        Data.IntMap.Internal
-        Data.IntMap.Internal.Debug
-        Data.IntMap.Internal.DeprecatedDebug
-        Data.IntMap.Strict
-        Data.IntMap.Strict.Internal
-        Data.IntSet
-        Data.IntSet.Internal
-        IntMapValidity
-        Utils.Containers.Internal.BitUtil
-        Utils.Containers.Internal.StrictPair
-        Utils.Containers.Internal.TypeError
-    type: exitcode-stdio-1.0
-    cpp-options: -DTESTING -DSTRICT
-
-    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
-    ghc-options: -O2
-    other-extensions: CPP, BangPatterns
-    include-dirs: include
-
-    build-depends:
-        HUnit,
-        QuickCheck >= 2.7.1,
-        test-framework,
-        test-framework-hunit,
-        test-framework-quickcheck2
-
-Test-suite intset-properties
-    hs-source-dirs: tests, .
-    main-is: intset-properties.hs
-    other-modules:
-        Data.IntSet
-        Data.IntSet.Internal
-        Data.Set
-        Data.Set.Internal
-        IntSetValidity
-        Utils.Containers.Internal.BitUtil
-        Utils.Containers.Internal.PtrEquality
-        Utils.Containers.Internal.StrictPair
-    type: exitcode-stdio-1.0
-    cpp-options: -DTESTING
-
-    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
-    ghc-options: -O2
-    other-extensions: CPP, BangPatterns
-    include-dirs: include
-
-    build-depends:
-        HUnit,
-        QuickCheck >= 2.7.1,
-        test-framework,
-        test-framework-hunit,
-        test-framework-quickcheck2
-
-Test-suite seq-properties
-    hs-source-dirs: tests, .
-    main-is: seq-properties.hs
-    other-modules:
-        Data.Sequence
-        Data.Sequence.Internal
-        Utils.Containers.Internal.StrictPair
-        Data.Sequence.Internal.Sorting
-        Utils.Containers.Internal.Coercions
-        Utils.Containers.Internal.State
-    type: exitcode-stdio-1.0
-    cpp-options: -DTESTING
-
-    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
-    ghc-options: -O2
-    other-extensions: CPP, BangPatterns
-    include-dirs: include
-
-    build-depends:
-        QuickCheck >= 2.7.1,
-        test-framework,
-        test-framework-quickcheck2,
-        transformers
-
-Test-suite tree-properties
-    hs-source-dirs: tests, .
-    main-is: tree-properties.hs
-    other-modules:
-        Data.Tree
-        Data.Sequence
-        Data.Sequence.Internal.Sorting
-        Utils.Containers.Internal.Coercions
-        Utils.Containers.Internal.State
-        Utils.Containers.Internal.StrictPair
-    type: exitcode-stdio-1.0
-    cpp-options: -DTESTING
-
-    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
-    ghc-options: -O2
-    other-extensions: CPP, BangPatterns
-    include-dirs: include
-
-    build-depends:
-        QuickCheck >= 2.7.1,
-        test-framework,
-        test-framework-quickcheck2,
-        transformers
-
-test-suite map-strictness-properties
-  hs-source-dirs: tests, .
-  main-is: map-strictness.hs
-  other-modules:
-      Data.Map.Internal
-      Data.Map.Internal.Debug
-      Data.Map.Internal.DeprecatedShowTree
-      Data.Map.Strict
-      Data.Map.Strict.Internal
-      Data.Set.Internal
-      Utils.Containers.Internal.BitQueue
-      Utils.Containers.Internal.BitUtil
-      Utils.Containers.Internal.PtrEquality
-      Utils.Containers.Internal.StrictMaybe
-      Utils.Containers.Internal.StrictPair
-      Utils.Containers.Internal.TypeError
-  type: exitcode-stdio-1.0
-
-  build-depends:
-    array >= 0.4.0.0,
-    base >= 4.6 && < 5,
-    ChasingBottoms,
-    deepseq >= 1.2 && < 1.5,
-    QuickCheck >= 2.7.1,
-    test-framework >= 0.3.3,
-    test-framework-quickcheck2 >= 0.2.9
-
-  ghc-options: -Wall
-  other-extensions: CPP, BangPatterns
-  include-dirs: include
-
-test-suite intmap-strictness-properties
-  hs-source-dirs: tests, .
-  main-is: intmap-strictness.hs
-  other-modules:
-      Data.IntMap.Internal
-      Data.IntMap.Internal.DeprecatedDebug
-      Data.IntMap.Strict
-      Data.IntMap.Strict.Internal
-      Data.IntSet.Internal
-      Utils.Containers.Internal.BitUtil
-      Utils.Containers.Internal.StrictPair
-      Utils.Containers.Internal.TypeError
-  type: exitcode-stdio-1.0
-  other-extensions: CPP, BangPatterns
-
-  build-depends:
-    array >= 0.4.0.0,
-    base >= 4.6 && < 5,
-    ChasingBottoms,
-    deepseq >= 1.2 && < 1.5,
-    QuickCheck >= 2.7.1,
-    test-framework >= 0.3.3,
-    test-framework-quickcheck2 >= 0.2.9
-
-  ghc-options: -Wall
-  include-dirs: include
-
-test-suite intset-strictness-properties
-  hs-source-dirs: tests, .
-  main-is: intset-strictness.hs
-  other-modules:
-      Data.IntSet
-      Data.IntSet.Internal
-      Utils.Containers.Internal.BitUtil
-      Utils.Containers.Internal.StrictPair
-      Utils.Containers.Internal.TypeError
-  type: exitcode-stdio-1.0
-  other-extensions: CPP, BangPatterns
-
-  build-depends:
-    array >= 0.4.0.0,
-    base >= 4.6 && < 5,
-    ChasingBottoms,
-    deepseq >= 1.2 && < 1.5,
-    QuickCheck >= 2.7.1,
-    test-framework >= 0.3.3,
-    test-framework-quickcheck2 >= 0.2.9
-
-  ghc-options: -Wall
-  include-dirs: include
-
-test-suite listutils-properties
-  hs-source-dirs: tests, .
-  main-is: listutils-properties.hs
-  other-modules:
-      Data.Containers.ListUtils
-      Utils.Containers.Internal.TypeError
-  type: exitcode-stdio-1.0
-
-  build-depends:
-    base >= 4.6 && < 5,
-    ChasingBottoms,
-    deepseq >= 1.2 && < 1.5,
-    QuickCheck >= 2.7.1,
-    test-framework >= 0.3.3,
-    test-framework-quickcheck2 >= 0.2.9
-
-  ghc-options: -Wall
-  include-dirs: include
similarity index 100%
rename from LICENSE
rename to containers/LICENSE
similarity index 100%
rename from README.md
rename to containers/README.md
similarity index 100%
rename from Setup.hs
rename to containers/Setup.hs
similarity index 100%
rename from changelog.md
rename to containers/changelog.md
diff --git a/containers/containers.cabal b/containers/containers.cabal
new file mode 100644 (file)
index 0000000..fc71732
--- /dev/null
@@ -0,0 +1,83 @@
+name: containers
+version: 0.6.0.1
+license: BSD3
+license-file: LICENSE
+maintainer: libraries@haskell.org
+bug-reports: https://github.com/haskell/containers/issues
+synopsis: Assorted concrete container types
+category: Data Structures
+description:
+    .
+    This package contains efficient general-purpose implementations
+    of various immutable container types including sets, maps, sequences,
+    trees, and graphs.
+    .
+    For a walkthrough of what this package provides with examples of common
+    operations see the [containers
+    introduction](https://haskell-containers.readthedocs.io).
+    .
+    The declared cost of each operation is either worst-case or amortized, but
+    remains valid even if structures are shared.
+
+build-type: Simple
+cabal-version:  >=1.8
+extra-source-files:
+    include/containers.h
+    changelog.md
+
+tested-with: GHC==8.6.4, GHC==8.4.4, GHC==8.2.2, GHC==8.0.2, GHC==7.10.3, GHC==7.8.4, GHC==7.6.3
+
+source-repository head
+    type:     git
+    location: http://github.com/haskell/containers.git
+
+Library
+    build-depends: base >= 4.6 && < 5, array >= 0.4.0.0, deepseq >= 1.2 && < 1.5
+    hs-source-dirs: src
+    ghc-options: -O2 -Wall
+
+    other-extensions: CPP, BangPatterns
+
+    exposed-modules:
+        Data.Containers.ListUtils
+        Data.IntMap
+        Data.IntMap.Lazy
+        Data.IntMap.Strict
+        Data.IntMap.Strict.Internal
+        Data.IntMap.Internal
+        Data.IntMap.Internal.Debug
+        Data.IntMap.Merge.Lazy
+        Data.IntMap.Merge.Strict
+        Data.IntSet.Internal
+        Data.IntSet
+        Data.Map
+        Data.Map.Lazy
+        Data.Map.Merge.Lazy
+        Data.Map.Strict.Internal
+        Data.Map.Strict
+        Data.Map.Merge.Strict
+        Data.Map.Internal
+        Data.Map.Internal.Debug
+        Data.Set.Internal
+        Data.Set
+        Data.Graph
+        Data.Sequence
+        Data.Sequence.Internal
+        Data.Sequence.Internal.Sorting
+        Data.Tree
+        Utils.Containers.Internal.BitUtil
+        Utils.Containers.Internal.BitQueue
+        Utils.Containers.Internal.StrictPair
+
+    other-modules:
+        Utils.Containers.Internal.State
+        Utils.Containers.Internal.StrictMaybe
+        Utils.Containers.Internal.PtrEquality
+        Utils.Containers.Internal.Coercions
+    if impl(ghc)
+      other-modules:
+        Utils.Containers.Internal.TypeError
+        Data.Map.Internal.DeprecatedShowTree
+        Data.IntMap.Internal.DeprecatedDebug
+
+    include-dirs: include
similarity index 100%
rename from docs/.gitignore
rename to containers/docs/.gitignore
similarity index 100%
rename from docs/Makefile
rename to containers/docs/Makefile
similarity index 100%
rename from docs/conf.py
rename to containers/docs/conf.py
similarity index 100%
rename from docs/index.rst
rename to containers/docs/index.rst
similarity index 100%
rename from docs/intro.rst
rename to containers/docs/intro.rst
similarity index 100%
rename from docs/make.bat
rename to containers/docs/make.bat
similarity index 100%
rename from docs/map.rst
rename to containers/docs/map.rst
similarity index 100%
rename from docs/set.rst
rename to containers/docs/set.rst
similarity index 100%
rename from prologue.txt
rename to containers/prologue.txt
similarity index 100%
rename from Data/Graph.hs
rename to containers/src/Data/Graph.hs
similarity index 100%
rename from Data/IntMap.hs
rename to containers/src/Data/IntMap.hs
similarity index 100%
rename from Data/IntSet.hs
rename to containers/src/Data/IntSet.hs
similarity index 100%
rename from Data/Map.hs
rename to containers/src/Data/Map.hs
similarity index 100%
rename from Data/Set.hs
rename to containers/src/Data/Set.hs
similarity index 100%
rename from Data/Tree.hs
rename to containers/src/Data/Tree.hs
diff --git a/docs/_extensions/haddock-autolink b/docs/_extensions/haddock-autolink
deleted file mode 160000 (submodule)
index 51c39ab..0000000
+++ /dev/null
@@ -1 +0,0 @@
-Subproject commit 51c39abba4ceacd5a171603e43453a6cfe7e2ac6
index efc3f50..03d1775 100644 (file)
@@ -1,11 +1,8 @@
 flags: {}
 packages:
-- '.'
+- containers
+- containers-tests
 
 ### Uncoment the resolver you want to use and re-run `stack build/test/bench`.
 # resolver: lts-10.0
-resolver: lts-12.13
-
-### ChasingBottoms is only in Stackage snapshots lts-7.24 and below.
-extra-deps:
-- ChasingBottoms-1.3.1.3
+resolver: lts-12.26