packages feed

semirings-0.2.0.0: semirings.cabal

name:          semirings
category:      Algebra, Data, Data Structures, Math, Maths, Mathematics
version:       0.2.0.0
license:       BSD3
cabal-version: >= 1.10
license-file:  LICENSE
author:        chessai
maintainer:    chessai <chessai1996@gmail.com>
stability:     provisional
homepage:      http://github.com/chessai/semirings
bug-reports:   http://github.com/chessai/semirings/issues
copyright:     Copyright (C) 2018 chessai
synopsis:      two monoids as one, in holy haskimony
description:
    In mathematics, a semiring is an algebraic structure consisting of a set together with two binary operations, one commutative and one associative. A semiring has two identity elements respective to its operations. Thus a semiring can be seen as a combination of two monoids, a commutative monoid and an associative monoid.
build-type:    Simple
extra-source-files: README.md CHANGELOG.md
tested-with:   GHC == 7.4.1 
             , GHC == 7.4.2
             , GHC == 7.6.1
             , GHC == 7.6.2
             , GHC == 7.8.1
             , GHC == 7.8.3
             , GHC == 7.8.4
             , GHC == 7.10.1
             , GHC == 7.10.2
             , GHC == 7.10.3
             , GHC == 8.0.1 
             , GHC == 8.0.2
             , GHC == 8.2.1 
             , GHC == 8.2.2
             , GHC == 8.4.1
             , GHC == 8.4.2
             , GHC == 8.4.3
             , GHC == 8.6.1

source-repository head
  type: git
  location: git://github.com/chessai/semirings.git

flag hashable
  description:
    You can disable the use of the `hashable` package using `-f-hashable`.
    .
    Disabling this may be useful for accelerating builds in sandboxes for expert users.
    .
    Note: `-f-hashable` implies `-f-unordered-containers`, as we are necessarily not able to supply those instances as well.
  default: True
  manual: True

flag containers
  description:
    You can disable the use of the `containers` package using `-f-containers`.
    .
    Disabling this may be useful for accelerating builds in sandboxes for expert users.
  default: True
  manual: True

flag unordered-containers
  description:
    You can disable the use of the `unordered-containers` package using `-f-unordered-containers`.
    .
    Disabling this may be useful for accelerating builds in sandboxes for expert users.
  default: True
  manual: True

flag vector
  description:
    You can disable the use of the `vector` package using `-f-vector`.
    .
    Disabling this may be useful for accelerating builds in sandboxes for expert users.
    default: True
    manual: True

library
  default-language: Haskell98
  ghc-options: -Wall

  build-depends:
      base >= 4.5 && < 5
    , integer-gmp
  
  if impl(ghc < 7.10)
    build-depends:
        nats >= 0.1 && < 2
      , transformers

  if impl(ghc < 8.0)
    build-depends: semigroups

  if impl(ghc < 7.8)
    build-depends: tagged

  if impl(ghc >= 7.2)
    exposed-modules:
      Data.Semiring
      Data.Semiring.Free
      Data.Star
  if impl(ghc >= 7.6.1)
    exposed-modules:
      Data.Semiring.Generic
   
    if flag(containers)
      build-depends: containers >= 0.5.4 && < 0.6.1.0

    if flag(hashable)
      build-depends: hashable >= 1.1  && < 1.3

    if flag(hashable) && flag(unordered-containers)
      build-depends: unordered-containers >= 0.2  && < 0.3

    if flag(vector)
      build-depends: vector >= 0.7 && < 0.13.0.0