cabal-version:       2.4
name:                safe-numeric
version:             0.1
synopsis:            Safe arithmetic operations.
description:
 @safe-numeric@ provides safer numeric operators, that have more explicit
 behaviour in terms of overflow and underflow, and are harder to misuse.
homepage:            https://github.com/infinity0/hs-safe-numeric
bug-reports:         https://github.com/infinity0/hs-safe-numeric/issues
license:             Apache-2.0
license-file:        LICENSE
author:              Ximin Luo
maintainer:          infinity0@pwned.gg
copyright:           (c) 2021 by Ximin Luo
category:            Arithmetic, Numeric, Safe
extra-source-files:  CHANGELOG.md
tested-with:
  GHC ==8.0.2
   || ==8.2.2
   || ==8.4.4
   || ==8.6.5
   || ==8.8.3
   || ==8.10.4
   || ==9.0.1

library
  exposed-modules:     Safe.Numeric
  -- other-modules:
  -- other-extensions:
  build-depends:
      base             >=4.5.0.0 && <5
    , safe             >=0.3.12  && <4
    , wide-word        >=0.1.1.0 && <0.2
  hs-source-dirs:      src
  default-language:    Haskell2010
  ghc-options:         -Wall

test-suite doctests
  build-depends:
      base >=4.5.0.0
    , doctest
    , containers
  hs-source-dirs: test
  type: exitcode-stdio-1.0
  main-is: DocTests.hs
  default-language:    Haskell2010
  ghc-options:         -Wall