name: module-munging
version: '0.1.0.0'
github: jship/module-munging
license: MIT
author: Jason Shipman
maintainer: Jason Shipman
synopsis: Smash together text to make modules.
description: |
Thin, low-tech wrapper for smashing together raw text to make Haskell modules.
category: Codegen
extra-source-files:
- CHANGELOG.md
- LICENSE.md
- package.yaml
- README.md
language: GHC2021
default-extensions:
- BlockArguments
- DerivingStrategies
- ImportQualifiedPost
- LambdaCase
ghc-options:
# Draws heavy inspiration from this list: https://medium.com/mercury-bank/enable-all-the-warnings-a0517bc081c3
- -Weverything
- -Wno-missing-local-signatures # Warns if polymorphic local bindings do not have signatures
- -Wno-missing-exported-signatures # missing-exported-signatures turns off the more strict -Wmissing-signatures. See https://ghc.haskell.org/trac/ghc/ticket/14794#ticket
- -Wno-missing-import-lists # Requires explicit imports of _every_ function (e.g. ‘$’); too strict
- -Wno-missed-specializations # When GHC can’t specialize a polymorphic function
- -Wno-all-missed-specializations # See missed-specializations
- -Wno-unsafe # Don’t use Safe Haskell warnings
- -Wno-safe # Don’t use Safe Haskell warnings
- -Wno-missing-safe-haskell-mode # Don't warn if the Safe Haskell mode is unspecified
library:
dependencies:
- base >=4.11.0.0 && <5
source-dirs: library
tests:
module-munging-test-suite:
source-dirs: test-suite
main: Driver.hs
build-tools:
- hspec-discover
dependencies:
- base
- module-munging
- hspec
- string-interpolate
ghc-options:
- -rtsopts
- -threaded
- -with-rtsopts "-N"
# Disabling these because of hspec-discover-2.9.7 version in lts-20.26.
# 2.10.3+ has automatic disabling of warnings in the generated driver, and
# that version is available in lts-21 and onward.
# See https://github.com/hspec/hspec/issues/702 for details.
when:
- condition: "!flag(recent-hspec-discover)"
ghc-options:
- -Wno-prepositive-qualified-module
- -Wno-missing-export-lists
flags:
recent-hspec-discover:
description: Assumes hspec-discover version is 2.10.3+
default: true
manual: true