util-logict (empty) → 0.0.0.0
raw patch · 7 files changed
+159/−0 lines, 7 filesdep +basedep +gaugedep +logict
Dependencies added: base, gauge, logict, util-logict
Files
- CHANGELOG.md +11/−0
- LICENSE +29/−0
- README.md +7/−0
- bench/Main.hs +7/−0
- src/Util/Monad/Logic/Class.hs +23/−0
- test/Spec.hs +4/−0
- util-logict.cabal +78/−0
+ CHANGELOG.md view
@@ -0,0 +1,11 @@+# Changelog++`util-logict.hs` uses [PVP Versioning][1].+The changelog is available [on GitHub][2].++## 0.0.0.0++* Initially created.++[1]: https://pvp.haskell.org+[2]: https://github.com/strake/util-logict.hs/releases
+ LICENSE view
@@ -0,0 +1,29 @@+BSD 3-Clause License++Copyright (c) 2020, M Farkas-Dyck+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 copyright holder nor the names of its+ contributors may be used to endorse or promote products derived from+ this software without specific prior written permission.++THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "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 COPYRIGHT HOLDER 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.
+ README.md view
@@ -0,0 +1,7 @@+# util-logict.hs++[](https://travis-ci.org/strake/util-logict.hs)+[](https://hackage.haskell.org/package/util-logict.hs)+[](LICENSE)++See README for more info
+ bench/Main.hs view
@@ -0,0 +1,7 @@+module Main (main) where++import Gauge.Main+++main :: IO ()+main = defaultMain [bench "const" (whnf const ())]
+ src/Util/Monad/Logic/Class.hs view
@@ -0,0 +1,23 @@+module Util.Monad.Logic.Class where++import Control.Applicative+import Control.Monad (MonadPlus, guard)+import Control.Monad.Logic.Class++infixr 7 \/+(\/) :: MonadLogic m => m a -> m a -> m a+(\/) = interleave++infixr 8 ><+(><) :: MonadLogic m => m a -> m b -> m (a, b)+(><) = liftL2 (,)++infixl 4 <~>+(<~>) :: MonadLogic m => m (a -> b) -> m a -> m b+fs <~> as = fs >>- (<$> as)++liftL2 :: MonadLogic m => (a -> b -> c) -> m a -> m b -> m c+liftL2 f as bs = f <$> as <~> bs++liftL3 :: MonadLogic m => (a -> b -> c -> d) -> m a -> m b -> m c -> m d+liftL3 f as bs cs = f <$> as <~> bs <~> cs
+ test/Spec.hs view
@@ -0,0 +1,4 @@+module Main (main) where++main :: IO ()+main = putStrLn ("Test suite not yet implemented" :: String)
+ util-logict.cabal view
@@ -0,0 +1,78 @@+cabal-version: 2.4+name: util-logict+version: 0.0.0.0+synopsis: See README for more info+description: See README for more info+homepage: https://github.com/strake/util-logict.hs+bug-reports: https://github.com/strake/util-logict.hs/issues+license: BSD-3-Clause+license-file: LICENSE+author: M Farkas-Dyck+maintainer: strake888@gmail.com+copyright: 2020 M Farkas-Dyck+category: Control+build-type: Simple+extra-doc-files: README.md+ , CHANGELOG.md+tested-with: GHC == 8.6.5++common c+ build-depends: base ^>= 4.8 || ^>= 4.9 || ^>= 4.10 || ^>= 4.11 || ^>= 4.12 || ^>= 4.13+ , logict ^>= 0.7.0.2+ ghc-options: -Wall+ -Wcompat+ -Wredundant-constraints+ -Wno-name-shadowing+ -Wincomplete-uni-patterns+ -Wincomplete-record-updates+ -Werror=incomplete-patterns+ -Werror=incomplete-uni-patterns+ -Werror=incomplete-record-updates+ -Werror=missing-fields+ -Werror=missing-methods+ default-language: Haskell2010+ default-extensions: UnicodeSyntax+ LambdaCase+ EmptyCase+ InstanceSigs+ PartialTypeSignatures+ PolyKinds+ ConstraintKinds+ FlexibleContexts+ FlexibleInstances+ MonadComprehensions+ StandaloneDeriving+ DeriveFunctor+ DeriveFoldable+ DeriveTraversable++library+ import: c+ hs-source-dirs: src+ exposed-modules: Util.Monad.Logic.Class+ build-depends:++test-suite test+ import: c+ type: exitcode-stdio-1.0+ hs-source-dirs: test+ main-is: Spec.hs+ build-depends: util-logict+ ghc-options: -threaded+ -rtsopts+ -with-rtsopts=-N++benchmark bench+ import: c+ type: exitcode-stdio-1.0+ hs-source-dirs: bench+ main-is: Main.hs+ build-depends: gauge+ , util-logict+ ghc-options: -threaded+ -rtsopts+ -with-rtsopts=-N++source-repository head+ type: git+ location: https://github.com/strake/util-logict.hs.git