packages feed

automaton-1.8: automaton.cabal

cabal-version: 3.0
name: automaton
version: 1.8
synopsis: Effectful streams and automata in coalgebraic encoding
description:
  Effectful streams have an internal state and a step function.
  Varying the effect type, this gives many different useful concepts:
  For example with a reader effect, it results in automata (a.k.a transducers or state machines).

license: MIT
license-file: LICENSE
author: Manuel Bärenz
maintainer: programming@manuelbaerenz.de
category: Streaming
build-type: Simple
extra-doc-files:
  CHANGELOG.md
  README.md

source-repository head
  type: git
  location: https://github.com/turion/rhine.git

source-repository this
  type: git
  location: https://github.com/turion/rhine.git
  tag: v1.6

common opts
  build-depends:
    MonadRandom >=0.5,
    base >=4.18 && <4.22,
    changeset ^>=0.2,
    containers >=0.5,
    free >=5.1,
    mmorph ^>=1.2,
    mtl >=2.2 && <2.4,
    profunctors ^>=5.6,
    selective ^>=0.7,
    semialign >=1.2 && <=1.4,
    simple-affine-space ^>=0.2,
    sop-core ^>=0.5,
    these >=1.1 && <=1.3,
    time-domain ^>=1.8,
    transformers >=0.5,
    witherable ^>=0.5,

  if flag(dev)
    ghc-options: -Werror
  ghc-options:
    -W

  default-extensions:
    ApplicativeDo
    Arrows
    DataKinds
    DerivingStrategies
    DerivingVia
    ExistentialQuantification
    FlexibleContexts
    FlexibleInstances
    GADTs
    GeneralizedNewtypeDeriving
    ImportQualifiedPost
    InstanceSigs
    LambdaCase
    MultiParamTypeClasses
    NamedFieldPuns
    NoStarIsType
    NumericUnderscores
    RankNTypes
    ScopedTypeVariables
    StandaloneDeriving
    TupleSections
    TypeApplications
    TypeFamilies
    TypeOperators

  default-language: Haskell2010

library
  import: opts
  exposed-modules:
    Data.Automaton
    Data.Automaton.Filter
    Data.Automaton.Recursive
    Data.Automaton.Schedule
    Data.Automaton.Schedule.Trans
    Data.Automaton.Trans.Accum
    Data.Automaton.Trans.Changeset
    Data.Automaton.Trans.Except
    Data.Automaton.Trans.Maybe
    Data.Automaton.Trans.RWS
    Data.Automaton.Trans.Random
    Data.Automaton.Trans.Reader
    Data.Automaton.Trans.State
    Data.Automaton.Trans.Writer
    Data.Stream
    Data.Stream.Except
    Data.Stream.Filter
    Data.Stream.Internal
    Data.Stream.Optimized
    Data.Stream.Recursive
    Data.Stream.Result

  other-modules:
    Data.Automaton.Trans.Except.Internal
    Data.Stream.Recursive.Except

  hs-source-dirs: src

test-suite automaton-test
  import: opts
  type: exitcode-stdio-1.0
  hs-source-dirs: test
  main-is: Main.hs
  other-modules:
    Automaton
    Automaton.Except
    Automaton.Filter
    Automaton.Schedule
    Automaton.Trans.Accum
    Automaton.Trans.Changeset
    Stream

  build-depends:
    QuickCheck >=2.14 && <2.16,
    automaton,
    tasty >=1.4 && <1.6,
    tasty-hunit ^>=0.10,
    tasty-quickcheck >=0.10 && <0.12,

executable UserSawtooth
  import: opts
  hs-source-dirs: examples
  main-is: UserSawtooth.hs
  build-depends:
    automaton

executable ForeverSawtooth
  import: opts
  hs-source-dirs: examples
  main-is: ForeverSawtooth.hs
  build-depends:
    automaton

flag dev
  description: Enable warnings as errors. Active on ci.
  default: False
  manual: True