Commit 86629015 authored by ijones's avatar ijones
Browse files

cleaned up some types

parent 17d3f6d4
......@@ -444,7 +444,7 @@ registerCmd = Cmd {
cmdAction = RegisterCmd False
}
-- | Flags to @register@: (user package, verbose)
-- | Flags to @register@ and @unregister@: (user package, verbose)
type RegisterFlags = (Bool,Int)
parseRegisterArgs :: RegisterFlags -> [String] -> [OptDescr a] ->
......
......@@ -54,7 +54,7 @@ module Distribution.Simple.Register (
import Distribution.Simple.LocalBuildInfo (LocalBuildInfo(..))
import Distribution.Simple.Install (mkLibDir)
import Distribution.Setup (CompilerFlavor(..), Compiler(..))
import Distribution.Setup (CompilerFlavor(..), Compiler(..), RegisterFlags)
import Distribution.PackageDescription (setupMessage, PackageDescription(..),
BuildInfo(..), Library(..))
import Distribution.Package (PackageIdentifier(..), showPackageId)
......@@ -89,7 +89,7 @@ import HUnit (Test)
-- then we use that file, perhaps creating it.
register :: PackageDescription -> LocalBuildInfo
-> (Bool,Int) -- ^Install in the user's database?; verbose
-> RegisterFlags -- ^Install in the user's database?; verbose
-> IO ()
register pkg_descr lbi (userInst,verbose)
| isNothing (library pkg_descr) = do
......@@ -201,7 +201,7 @@ mkInstalledPackageInfo pkg_descr lbi
-- -----------------------------------------------------------------------------
-- Unregistration
unregister :: PackageDescription -> LocalBuildInfo -> (Bool,Int) -> IO ()
unregister :: PackageDescription -> LocalBuildInfo -> RegisterFlags -> IO ()
unregister pkg_descr lbi (user_unreg, verbose) = do
setupMessage "Unregistering" pkg_descr
let ghc_63_plus = compilerVersion (compiler lbi) >= Version [6,3] []
......@@ -229,8 +229,6 @@ unregister pkg_descr lbi (user_unreg, verbose) = do
_ ->
die ("only unregistering with GHC and Hugs is implemented")
-- ------------------------------------------------------------
-- * Testing
-- ------------------------------------------------------------
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment