module Distribution.Types.ParStrat where
data ParStratX sem
=
NumJobs (Maybe Int)
|
UseSem sem
|
Serial
deriving (Int -> ParStratX sem -> ShowS
[ParStratX sem] -> ShowS
ParStratX sem -> String
(Int -> ParStratX sem -> ShowS)
-> (ParStratX sem -> String)
-> ([ParStratX sem] -> ShowS)
-> Show (ParStratX sem)
forall sem. Show sem => Int -> ParStratX sem -> ShowS
forall sem. Show sem => [ParStratX sem] -> ShowS
forall sem. Show sem => ParStratX sem -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: forall sem. Show sem => Int -> ParStratX sem -> ShowS
showsPrec :: Int -> ParStratX sem -> ShowS
$cshow :: forall sem. Show sem => ParStratX sem -> String
show :: ParStratX sem -> String
$cshowList :: forall sem. Show sem => [ParStratX sem] -> ShowS
showList :: [ParStratX sem] -> ShowS
Show)
type ParStrat = ParStratX String
type ParStratInstall = ParStratX Int
isParallelBuild :: ParStratX n -> Bool
isParallelBuild :: forall n. ParStratX n -> Bool
isParallelBuild ParStratX n
Serial = Bool
False
isParallelBuild (NumJobs (Just Int
1)) = Bool
False
isParallelBuild (NumJobs Maybe Int
_) = Bool
True
isParallelBuild UseSem{} = Bool
True