packages feed

lifetimes-0.2.0.0: lifetimes.cabal

cabal-version:       2.2
name:                lifetimes
version:             0.2.0.0
synopsis:            Flexible manual resource management
description:
  The lifetimes package provides support for manual resource management,
  in a way that is more flexible than what is provided by @resourcet@ or
  @bracket@.
  .
  Like @resourcet@, this package allows releasing acquired resources early.
  In addition, it also provides move semantics: resources can be moved to
  a different lifetime after they are acquired. Lifetimes are first class
  values, which can themselves be acquired as resources, allowing for
  heirarchical management as well.
homepage:            https://github.com/zenhack/haskell-lifetimes
license:             Apache-2.0

license-file:        LICENSE
author:              Ian Denhardt
maintainer:          ian@zenhack.net
copyright:           2021-2023 Ian Denhardt
-- category:
  -- Codec
  -- Concurrency
  -- Control
  -- Data
  -- Database
  -- Development
  -- Distribution
  -- Game
  -- Graphics
  -- Language
  -- Math
  -- Network
  -- Sound
  -- System
  -- Testing
  -- Text
  -- Web

build-type:          Simple
extra-source-files:
    CHANGELOG.md
  , README.md
  , .gitignore

source-repository head
  type:     git
  branch:   main
  location: https://github.com/zenhack/haskell-lifetimes

common shared-opts
  default-extensions:
      NoImplicitPrelude
    , OverloadedStrings
  build-depends:
      base >=4.12 && <5
    , async ^>=2.2.4
    , containers ^>=0.6.2
    , stm ^>=2.5
    , monad-stm ^>=0.1
    , transformers ^>=0.5.6
    , zenhack-prelude ^>=0.1
  default-language:    Haskell2010

library
  import: shared-opts
  hs-source-dirs:      src
  exposed-modules:
      Lifetimes
    , Lifetimes.Async
    , Lifetimes.Rc
    , Lifetimes.Gc
test-suite tests
  import: shared-opts
  build-depends:
      lifetimes
    , hspec ^>=2.7.6
    , safe-exceptions ^>=0.1.7
  type: exitcode-stdio-1.0
  hs-source-dirs: tests
  main-is: Main.hs