diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /dev-haskell/chasingbottoms |
reinit the tree, so we can have metadata
Diffstat (limited to 'dev-haskell/chasingbottoms')
-rw-r--r-- | dev-haskell/chasingbottoms/Manifest | 11 | ||||
-rw-r--r-- | dev-haskell/chasingbottoms/chasingbottoms-1.3.0.11-r1.ebuild | 46 | ||||
-rw-r--r-- | dev-haskell/chasingbottoms/chasingbottoms-1.3.0.13.ebuild | 41 | ||||
-rw-r--r-- | dev-haskell/chasingbottoms/chasingbottoms-1.3.0.14.ebuild | 39 | ||||
-rw-r--r-- | dev-haskell/chasingbottoms/chasingbottoms-1.3.1.2.ebuild | 46 | ||||
-rw-r--r-- | dev-haskell/chasingbottoms/metadata.xml | 102 |
6 files changed, 285 insertions, 0 deletions
diff --git a/dev-haskell/chasingbottoms/Manifest b/dev-haskell/chasingbottoms/Manifest new file mode 100644 index 000000000000..e246e4f79438 --- /dev/null +++ b/dev-haskell/chasingbottoms/Manifest @@ -0,0 +1,11 @@ +DIST ChasingBottoms-1.3.0.11.tar.gz 31437 SHA256 9cf0c58617ed0877eab06a3a71e4dbcf911d7f2bf64bfe3c9cc91e7f3181e303 SHA512 acf939e4060b08a02fd1bd15473911551e834373b8e4e50f36cd832b64ec3798e9a41d3b26fdc9e9b84648862617da8ba859ee453086240f566ce4ae8bc0301e WHIRLPOOL 52e9255acbda1826f06bdc272a6ff9414325143e792db6a66988d43ce299857ea6a086258ee683f8da1222cda2f378a81c6dcd48782a879e9cc9323b72fa68f9 +DIST ChasingBottoms-1.3.0.13.tar.gz 31474 SHA256 f40e250db12ab76c31e1ed78ce3d11a84f601ab2290fe946cfe437669a3468b9 SHA512 050d66670a77de274f16d70dfbc231ab469067ce34af962a851c7f041b7e0812bb6480e3b3166e4ceda2509454ff3d1d85fdd977f63471d6f45c1162184aeb7d WHIRLPOOL a5ad6a40e6b217227eb0c9896388f22f1d41ea03a2f5c52f7d67a602e33571b46d036ba23e2a13f8def1a30c323c1e7348ce79aebfc5aea4ef5f0ca5f3970fee +DIST ChasingBottoms-1.3.0.14.tar.gz 31485 SHA256 a4a296b09d8158d25ace6fdaf17a445f30e3af14f753e6bc80282806c309704a SHA512 672dbfb236b14cedd7c0039476c7d799b1718843336a60905816faf6f5d80491eaef59bdf4a8b000f0104ab452760964b64c5f09293535d517b3a33e6d382e13 WHIRLPOOL 462029248115f51fd0041f1dfd4caf4efbd0160a564c8398b9160fe3c426b6fff7dfc41441b8f27597a265afa482928787ee0f421d2ef7dbc6558c5202774c84 +DIST ChasingBottoms-1.3.1.2.tar.gz 31555 SHA256 796e278b60c4a24eb6772155ea0edff9e20f96d396cfcd6c5a55d10a3bd2b8d6 SHA512 84d05b26916bda14bd0b33ff90154da88b5a8c01cae692a8cc11339aea2259b8d0001f3c3b21199ef59efbfb028dfd877f11f8543b55828ecf563f7c5cd711e0 WHIRLPOOL 4bd1f252d16d8ae47dc379b15cf293afef5a209766b86e3175d5d807f0acd50baa4550c0f831f0d74297cfdb02023616544af7f044d7fa322f1350f07d3cdb70 +EBUILD chasingbottoms-1.3.0.11-r1.ebuild 1124 SHA256 a54c1b09a0663ee143b65a1646895de19166d23805f08f1597171b11a48ddfc9 SHA512 ed3604103258a011cfc46c197e46c891635d91676f1f37b3d2550d3c460166f0ca72d8f650ceb6d2aa13c62c9da8dde7aa050cd946b6bd39bb829d1477408d4c WHIRLPOOL c0fac96a71f1214e08f61a834160187d052040913b267502a218a679b1ab088964d72c02bcf4f7ce6bb0890456445cfbd41b08de036350e5679e6c7a725b45e8 +EBUILD chasingbottoms-1.3.0.13.ebuild 1081 SHA256 69b305963821eb5ea84ccfacaf3c380f58a8621f38c6a6311cd0892f6ecdefd0 SHA512 975f528910ead3595ecb3d8d7bfb956fbf32fabf725aae40dc8e6b65a06528fca2040f8f8fc6b7329aa8735e4c008dabbe7e23362fb38878da0cf41df3e55356 WHIRLPOOL 06f9366f0f2eb7d6c12fc4cbd22e828a7d3705bbf732bb704573539d250299f115e2f6c9a469176663ec1d37c7d48bd86c1c9c88f33708664d0392bb1b35abe4 +EBUILD chasingbottoms-1.3.0.14.ebuild 1052 SHA256 953ae32aedf094c6564df563ab9e3aebee4d967f01523e6df17e0dcb28a26d7c SHA512 9338f4ab5ebef00e7cf741cdbba770b6b977d29cd027249ed468478047ef67453aa5bbebfce302bc6a7b82536a275fb1f67eeb2c521b94974b34ac5a74b5ca7d WHIRLPOOL ba63046992d38d60808eb904df115e5dcc422fcee019abbf1bb7dbe2d96c197578215bc87b9a29048e13776aec42c7e21cb6e92943f3245345070ce9ab153a2c +EBUILD chasingbottoms-1.3.1.2.ebuild 1134 SHA256 1878866510367a3707fb3a2e3e017ea1337fa20e25aaa7ab95de7deebc252b21 SHA512 dd6d7de4e69335251beb6d85880c5a802bffbe7f6f529562c6fe8e8a895445d6c45f65c8de6b3325993d142eadc089140f879298062a54e2d64c1f3d22c6fbdb WHIRLPOOL 8aaae3db1951ab82c56b86f6dae745cc987a52a1fdbeeb8380129e26c8f095000e60936c695eadd0867f80cecce97b6df9a8129fa6bc21a16fc12f43f6d4d43e +MISC ChangeLog 3597 SHA256 d92e79528813055ee74b8bbd24f9d1d6ef55d35a0b5badf56c82df3d3eb3062a SHA512 bd8f9ff8801dd3f4bb84ec1dc2414d1b728feeaef8fe621bf5574c4808ca1ab0e7cb5af11707938121c25bbcba19ad5361bb7c2087fbc19045fc007ca92c6b61 WHIRLPOOL ab83f354caa011db4c0bb5d340dcccf915cc48c9f60f97ee93a4b45d7294fcda62a99f1121ac2bd9393efd9949af65f16613080cf6ae24ee210961b8dabe16e6 +MISC ChangeLog-2015 2695 SHA256 279e637e7bfcd59499bfd1732e85063703f1f82996855c2f69a4a2b4b5146948 SHA512 acc358610d33a8e684af47e43346c6f34de03a853ebfe84ca6d23a7ef1a9bf6094b70db0754da299e054d445685922b3be02007b1eb3baf03d2b49e2cd4c2213 WHIRLPOOL f53f2c6cab92e0de1a737581654291cd2c081715c37498469bd0326da3fe0efac82d4fef3bd6221a34ff66015b60d84d79d8c701c5e320d3978137e0c41d5486 +MISC metadata.xml 4089 SHA256 6b2e6cbc414c8ed097ec32153d62503726841b8105d575facbc53e9d450b72d5 SHA512 d4423f7dbf1b4dc0e8a4b6803c55bec2a82ba31fe2609c5e68a7708b8a7bd8a65ae58db306772a9772e6b1e89752c918e2a04e3a914cf40ddebc286c3b98414c WHIRLPOOL bfb7caf7e2485afd75a517e71238cda959a118ea81f0281543664196906cabfb36b83ff6a3e76ddee032bfb615a0afaa22237512c6fbb3494704e536222c2403 diff --git a/dev-haskell/chasingbottoms/chasingbottoms-1.3.0.11-r1.ebuild b/dev-haskell/chasingbottoms/chasingbottoms-1.3.0.11-r1.ebuild new file mode 100644 index 000000000000..beb123919b92 --- /dev/null +++ b/dev-haskell/chasingbottoms/chasingbottoms-1.3.0.11-r1.ebuild @@ -0,0 +1,46 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +# ebuild generated by hackport 0.4.4.9999 +#hackport: flags: -build-tests + +CABAL_FEATURES="lib profile haddock hoogle hscolour test-suite" +inherit haskell-cabal + +MY_PN="ChasingBottoms" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="For testing partial and infinite values" +HOMEPAGE="http://hackage.haskell.org/package/ChasingBottoms" +SRC_URI="mirror://hackage/packages/archive/${MY_PN}/${PV}/${MY_P}.tar.gz" + +LICENSE="MIT" +SLOT="0/${PV}" +KEYWORDS="amd64 x86" +IUSE="" + +RESTRICT=test # takes a lot + +RDEPEND=">=dev-haskell/mtl-1.1:=[profile?] <dev-haskell/mtl-2.3:=[profile?] + >=dev-haskell/quickcheck-2.1:2=[profile?] + >=dev-haskell/random-1.0:=[profile?] <dev-haskell/random-1.2:=[profile?] + >=dev-haskell/syb-0.1.0.2:=[profile?] <dev-haskell/syb-0.5:=[profile?] + >=dev-lang/ghc-7.4.1:= +" +DEPEND="${RDEPEND} + >=dev-haskell/cabal-1.9.2 +" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + cabal_chdeps \ + 'QuickCheck >= 2.1 && < 2.8' 'QuickCheck >= 2.1' +} + +src_configure() { + haskell-cabal_src_configure \ + --flag=-build-tests +} diff --git a/dev-haskell/chasingbottoms/chasingbottoms-1.3.0.13.ebuild b/dev-haskell/chasingbottoms/chasingbottoms-1.3.0.13.ebuild new file mode 100644 index 000000000000..1b1f14687b0b --- /dev/null +++ b/dev-haskell/chasingbottoms/chasingbottoms-1.3.0.13.ebuild @@ -0,0 +1,41 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +# ebuild generated by hackport 0.4.5.9999 +#hackport: flags: -build-tests + +CABAL_FEATURES="lib profile haddock hoogle hscolour test-suite" +inherit haskell-cabal + +MY_PN="ChasingBottoms" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="For testing partial and infinite values" +HOMEPAGE="http://hackage.haskell.org/package/ChasingBottoms" +SRC_URI="mirror://hackage/packages/archive/${MY_PN}/${PV}/${MY_P}.tar.gz" + +LICENSE="MIT" +SLOT="0/${PV}" +KEYWORDS="~amd64 ~x86" +IUSE="" + +RESTRICT=test # takes a lot + +RDEPEND=">=dev-haskell/mtl-1.1:=[profile?] <dev-haskell/mtl-2.3:=[profile?] + >=dev-haskell/quickcheck-2.1:2=[profile?] <dev-haskell/quickcheck-2.9:2=[profile?] + >=dev-haskell/random-1.0:=[profile?] <dev-haskell/random-1.2:=[profile?] + >=dev-haskell/syb-0.1.0.2:=[profile?] <dev-haskell/syb-0.6:=[profile?] + >=dev-lang/ghc-7.4.1:= +" +DEPEND="${RDEPEND} + >=dev-haskell/cabal-1.9.2 +" + +S="${WORKDIR}/${MY_P}" + +src_configure() { + haskell-cabal_src_configure \ + --flag=-build-tests +} diff --git a/dev-haskell/chasingbottoms/chasingbottoms-1.3.0.14.ebuild b/dev-haskell/chasingbottoms/chasingbottoms-1.3.0.14.ebuild new file mode 100644 index 000000000000..cdc5d93dcc76 --- /dev/null +++ b/dev-haskell/chasingbottoms/chasingbottoms-1.3.0.14.ebuild @@ -0,0 +1,39 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +# ebuild generated by hackport 0.4.7.9999 +#hackport: flags: -build-tests + +CABAL_FEATURES="lib profile haddock hoogle hscolour test-suite" +inherit haskell-cabal + +MY_PN="ChasingBottoms" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="For testing partial and infinite values" +HOMEPAGE="http://hackage.haskell.org/package/ChasingBottoms" +SRC_URI="mirror://hackage/packages/archive/${MY_PN}/${PV}/${MY_P}.tar.gz" + +LICENSE="MIT" +SLOT="0/${PV}" +KEYWORDS="~amd64 ~x86" +IUSE="" + +RDEPEND=">=dev-haskell/mtl-1.1:=[profile?] <dev-haskell/mtl-2.3:=[profile?] + >=dev-haskell/quickcheck-2.1:2=[profile?] <dev-haskell/quickcheck-2.9:2=[profile?] + >=dev-haskell/random-1.0:=[profile?] <dev-haskell/random-1.2:=[profile?] + >=dev-haskell/syb-0.1.0.2:=[profile?] <dev-haskell/syb-0.7:=[profile?] + >=dev-lang/ghc-7.4.1:= +" +DEPEND="${RDEPEND} + >=dev-haskell/cabal-1.9.2 +" + +S="${WORKDIR}/${MY_P}" + +src_configure() { + haskell-cabal_src_configure \ + --flag=-build-tests +} diff --git a/dev-haskell/chasingbottoms/chasingbottoms-1.3.1.2.ebuild b/dev-haskell/chasingbottoms/chasingbottoms-1.3.1.2.ebuild new file mode 100644 index 000000000000..dd2b4df038a7 --- /dev/null +++ b/dev-haskell/chasingbottoms/chasingbottoms-1.3.1.2.ebuild @@ -0,0 +1,46 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +# ebuild generated by hackport 0.5.9999 +#hackport: flags: -build-tests + +CABAL_FEATURES="lib profile haddock hoogle hscolour test-suite" +inherit haskell-cabal + +MY_PN="ChasingBottoms" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="For testing partial and infinite values" +HOMEPAGE="http://hackage.haskell.org/package/ChasingBottoms" +SRC_URI="mirror://hackage/packages/archive/${MY_PN}/${PV}/${MY_P}.tar.gz" + +LICENSE="MIT" +SLOT="0/${PV}" +KEYWORDS="amd64 x86" +IUSE="" + +RDEPEND=">=dev-haskell/mtl-1.1:=[profile?] <dev-haskell/mtl-2.3:=[profile?] + >=dev-haskell/quickcheck-2.1:2=[profile?] <dev-haskell/quickcheck-2.10:2=[profile?] + >=dev-haskell/random-1.0:=[profile?] <dev-haskell/random-1.2:=[profile?] + >=dev-haskell/syb-0.1.0.2:=[profile?] <dev-haskell/syb-0.7:=[profile?] + >=dev-lang/ghc-7.4.1:= +" +DEPEND="${RDEPEND} + >=dev-haskell/cabal-1.9.2 +" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + default + + cabal_chdeps \ + 'base >= 4.0 && < 4.10' 'base >= 4.0' +} + +src_configure() { + haskell-cabal_src_configure \ + --flag=-build-tests +} diff --git a/dev-haskell/chasingbottoms/metadata.xml b/dev-haskell/chasingbottoms/metadata.xml new file mode 100644 index 000000000000..ec83e2946e46 --- /dev/null +++ b/dev-haskell/chasingbottoms/metadata.xml @@ -0,0 +1,102 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>haskell@gentoo.org</email> + <name>Gentoo Haskell</name> + </maintainer> + <longdescription> + Do you ever feel the need to test code involving bottoms (e.g. calls to + the @error@ function), or code involving infinite values? Then this + library could be useful for you. + + It is usually easy to get a grip on bottoms by showing a value and + waiting to see how much gets printed before the first exception is + encountered. However, that quickly gets tiresome and is hard to automate + using e.g. QuickCheck + (<http://www.cse.chalmers.se/~rjmh/QuickCheck/>). With this library you + can do the tests as simply as the following examples show. + + Testing explicitly for bottoms: + + [@> isBottom (head [\])@] @True@ + + [@> isBottom bottom@] @True@ + + [@> isBottom (\\_ -> bottom)@] @False@ + + [@> isBottom (bottom, bottom)@] @False@ + + Comparing finite, partial values: + + [@> ((bottom, 3) :: (Bool, Int)) ==! (bottom, 2+5-4)@] @True@ + + [@> ((bottom, bottom) :: (Bool, Int)) <! (bottom, 8)@] @True@ + + Showing partial and infinite values (@\\\/!@ is join and @\/\\!@ is meet): + + [@> approxShow 4 $ (True, bottom) \\\/! (bottom, \'b\')@] @\"Just (True, \'b\')\"@ + + [@> approxShow 4 $ (True, bottom) \/\\! (bottom, \'b\')@] @\"(_|_, _|_)\"@ + + [@> approxShow 4 $ ([1..\] :: [Int\])@] @\"[1, 2, 3, _\"@ + + [@> approxShow 4 $ (cycle [bottom\] :: [Bool\])@] @\"[_|_, _|_, _|_, _\"@ + + Approximately comparing infinite, partial values: + + [@> approx 100 [2,4..\] ==! approx 100 (filter even [1..\] :: [Int\])@] @True@ + + [@> approx 100 [2,4..\] \/=! approx 100 (filter even [bottom..\] :: [Int\])@] @True@ + + The code above relies on the fact that @bottom@, just as @error + \"...\"@, @undefined@ and pattern match failures, yield + exceptions. Sometimes we are dealing with properly non-terminating + computations, such as the following example, and then it can be nice to + be able to apply a time-out: + + [@> timeOut' 1 (reverse [1..5\])@] @Value [5,4,3,2,1]@ + + [@> timeOut' 1 (reverse [1..\])@] @NonTermination@ + + The time-out functionality can be used to treat \"slow\" computations as + bottoms: + + [@> let tweak = Tweak &#x7b; approxDepth = Just 5, timeOutLimit = Just 2 &#x7d;@] + + [@> semanticEq tweak (reverse [1..\], [1..\]) (bottom :: [Int\], [1..\] :: [Int\])@] @True@ + + [@> let tweak = noTweak &#x7b; timeOutLimit = Just 2 &#x7d;@] + + [@> semanticJoin tweak (reverse [1..\], True) ([\] :: [Int\], bottom)@] @Just ([],True)@ + + This can of course be dangerous: + + [@> let tweak = noTweak &#x7b; timeOutLimit = Just 0 &#x7d;@] + + [@> semanticEq tweak (reverse [1..100000000\]) (bottom :: [Integer\])@] @True@ + + Timeouts can also be applied to @IO@ computations: + + [@> let primes = unfoldr (\\(x:xs) -> Just (x, filter ((\/= 0) . (\`mod\` x)) xs)) [2..\]@] + + [@> timeOutMicro 100 (print $ filter ((== 1) . (\`mod\` 83)) primes)@] @[167,499,9NonTermination@ + + [@> timeOutMicro 100 (print $ take 6 $ filter ((== 1) . (\`mod\` 83)) primes)@] @[167,499,997,1163,1993NonTermination@ + + [@> timeOutMicro 100 (print $ take 6 $ filter ((== 1) . (\`mod\` 83)) primes)@] @[167,499,997,1163,1993,2657]@ + + [@ @] @Value ()@ + + For the underlying theory and a larger example involving use of + QuickCheck, see the article \"Chasing Bottoms, A Case Study in Program + Verification in the Presence of Partial and Infinite Values\" + (<http://www.cse.chalmers.se/~nad/publications/danielsson-jansson-mpc2004.html>). + + The code has been tested using GHC. Most parts can probably be + ported to other Haskell compilers, but this would require some work. + The @TimeOut@ functions require preemptive scheduling, and most of + the rest requires @Data.Generics@; @isBottom@ only requires + exceptions, though. + </longdescription> +</pkgmetadata> |