Skip to content

Commit

Permalink
fix compile of callers of hpack with too few constraints
Browse files Browse the repository at this point in the history
  • Loading branch information
kadoban committed Aug 24, 2017
1 parent 0e30e38 commit 3fa7078
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/Stack/Solver.hs
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ import Stack.Types.FlagName
import Stack.Types.PackageIdentifier
import Stack.Types.PackageName
import Stack.Types.Resolver
import Stack.Types.Runner
import Stack.Types.Version
import qualified System.Directory as D
import qualified System.FilePath as FP
Expand Down Expand Up @@ -488,7 +489,9 @@ getResolverConstraints menv mcompilerVersion stackYaml sd = do
-- a `hpack` `package.yaml` file exists, this will be used to generate a cabal
-- file.
-- Subdirectories can be included depending on the @recurse@ parameter.
findCabalFiles :: (MonadIO m, MonadLogger m) => Bool -> Path Abs Dir -> m [Path Abs File]
findCabalFiles
:: (MonadIO m, MonadLogger m, HasRunner env, MonadReader env m)
=> Bool -> Path Abs Dir -> m [Path Abs File]
findCabalFiles recurse dir = do
liftIO (findFiles dir isHpack subdirFilter) >>= mapM_ (hpack . parent)
liftIO (findFiles dir isCabal subdirFilter)
Expand Down Expand Up @@ -582,7 +585,9 @@ cabalPackagesCheck cabalfps noPkgMsg dupErrMsg = do
formatGroup :: [String] -> String
formatGroup = concatMap (\path -> "- " <> path <> "\n")

reportMissingCabalFiles :: (MonadIO m, MonadThrow m, MonadLogger m)
reportMissingCabalFiles
:: (MonadIO m, MonadThrow m, MonadLogger m,
HasRunner env, MonadReader env m)
=> [Path Abs File] -- ^ Directories to scan
-> Bool -- ^ Whether to scan sub-directories
-> m ()
Expand Down

0 comments on commit 3fa7078

Please sign in to comment.