chs-cabal 0.1.0.1 → 0.1.1.0
raw patch · 4 files changed
+25/−8 lines, 4 filesdep ~CabalPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: Cabal
API changes (from Hackage documentation)
+ Distribution.C2Hs: c2hsUserHooks :: UserHooks
Files
- CHANGELOG.md +6/−1
- chs-cabal.cabal +1/−1
- src/Distribution/C2Hs.hs +17/−6
- src/Distribution/C2Hs/TopSort.hs +1/−0
CHANGELOG.md view
@@ -1,8 +1,13 @@ # chs-cabal -## 0.1.0.1+## 0.1.1.0 + * Add `c2hsUserHooks` * Expand support for older GHCs++## 0.1.0.0++ * Better documentation ## 0.1.0.0
chs-cabal.cabal view
@@ -1,6 +1,6 @@ cabal-version: 1.18 name: chs-cabal-version: 0.1.0.1+version: 0.1.1.0 license: BSD3 license-file: LICENSE copyright: Copyright: (c) 2019 Vanessa McHale
src/Distribution/C2Hs.hs view
@@ -1,4 +1,12 @@+-- | Everything in this module is slightly morally dubious in that it works by+-- considering *all* modules to be @exposed-modules@ in the preprocessor phase.+--+-- This works in practice, but the Cabal API provides no guarantees this will+-- continue to be the case in the future. module Distribution.C2Hs ( defaultMainC2Hs+ -- * User hooks+ , c2hsUserHooks+ -- * Specialized hooks , c2hsBuildHooks , c2hsHaddockHooks , c2hsReplHooks@@ -26,13 +34,16 @@ import Distribution.Verbosity (Verbosity, normal) defaultMainC2Hs :: IO ()-defaultMainC2Hs = defaultMainWithHooks- simpleUserHooks { buildHook = c2hsBuildHooks- , haddockHook = c2hsHaddockHooks- , replHook = c2hsReplHooks- }+defaultMainC2Hs = defaultMainWithHooks c2hsUserHooks --- | Custom build hooks to be used with @.chs@ files which @\{#import#\}@ one+-- | @since 0.1.1.0+c2hsUserHooks :: UserHooks+c2hsUserHooks = simpleUserHooks { buildHook = c2hsBuildHooks+ , haddockHook = c2hsHaddockHooks+ , replHook = c2hsReplHooks+ }++-- | Custom build hooks to be used with @.chs@ files which @{\#import\#}@ one -- another. c2hsBuildHooks :: PackageDescription -> LocalBuildInfo -> UserHooks -> BuildFlags -> IO () c2hsBuildHooks = \pd lbi hooks bf -> do
src/Distribution/C2Hs/TopSort.hs view
@@ -1,3 +1,4 @@+-- | Topological sort for @.chs@ files according to @{\#import\#}@s. module Distribution.C2Hs.TopSort ( reorderC2Hs ) where import Control.Applicative (pure)