Cabal-2.4.1.0: A framework for packaging Haskell software

Safe HaskellNone
LanguageHaskell2010

Distribution.Types.GenericPackageDescription

Synopsis

Documentation

data GenericPackageDescription #

Instances
Eq GenericPackageDescription # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Data GenericPackageDescription # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> GenericPackageDescription -> c GenericPackageDescription #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c GenericPackageDescription #

toConstr :: GenericPackageDescription -> Constr #

dataTypeOf :: GenericPackageDescription -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c GenericPackageDescription) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c GenericPackageDescription) #

gmapT :: (forall b. Data b => b -> b) -> GenericPackageDescription -> GenericPackageDescription #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> GenericPackageDescription -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> GenericPackageDescription -> r #

gmapQ :: (forall d. Data d => d -> u) -> GenericPackageDescription -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> GenericPackageDescription -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> GenericPackageDescription -> m GenericPackageDescription #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> GenericPackageDescription -> m GenericPackageDescription #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> GenericPackageDescription -> m GenericPackageDescription #

Show GenericPackageDescription # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Generic GenericPackageDescription # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Associated Types

type Rep GenericPackageDescription :: Type -> Type #

Binary GenericPackageDescription # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

NFData GenericPackageDescription # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Package GenericPackageDescription # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

HasBuildInfos GenericPackageDescription # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

type Rep GenericPackageDescription # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

data Flag #

A flag can represent a feature to be included, or a way of linking a target against its dependencies, or in fact whatever you can think of.

Instances
Eq Flag # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

(==) :: Flag -> Flag -> Bool #

(/=) :: Flag -> Flag -> Bool #

Data Flag # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Flag -> c Flag #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Flag #

toConstr :: Flag -> Constr #

dataTypeOf :: Flag -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Flag) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Flag) #

gmapT :: (forall b. Data b => b -> b) -> Flag -> Flag #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Flag -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Flag -> r #

gmapQ :: (forall d. Data d => d -> u) -> Flag -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Flag -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Flag -> m Flag #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Flag -> m Flag #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Flag -> m Flag #

Show Flag # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

showsPrec :: Int -> Flag -> ShowS #

show :: Flag -> String #

showList :: [Flag] -> ShowS #

Generic Flag # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Associated Types

type Rep Flag :: Type -> Type #

Methods

from :: Flag -> Rep Flag x #

to :: Rep Flag x -> Flag #

Binary Flag # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

put :: Flag -> Put #

get :: Get Flag #

putList :: [Flag] -> Put #

NFData Flag # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

rnf :: Flag -> () #

type Rep Flag # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

type Rep Flag = D1 (MetaData "Flag" "Distribution.Types.GenericPackageDescription" "Cabal-2.4.1.0-4t2ut7bCQNuEj8DDES6BZk" False) (C1 (MetaCons "MkFlag" PrefixI True) ((S1 (MetaSel (Just "flagName") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 FlagName) :*: S1 (MetaSel (Just "flagDescription") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)) :*: (S1 (MetaSel (Just "flagDefault") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool) :*: S1 (MetaSel (Just "flagManual") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool))))

emptyFlag :: FlagName -> Flag #

A Flag initialized with default parameters.

data FlagName #

A FlagName is the name of a user-defined configuration flag

Use mkFlagName and unFlagName to convert from/to a String.

This type is opaque since Cabal-2.0

Since: 2.0.0.2

Instances
Eq FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Data FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> FlagName -> c FlagName #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c FlagName #

toConstr :: FlagName -> Constr #

dataTypeOf :: FlagName -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c FlagName) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c FlagName) #

gmapT :: (forall b. Data b => b -> b) -> FlagName -> FlagName #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> FlagName -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> FlagName -> r #

gmapQ :: (forall d. Data d => d -> u) -> FlagName -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> FlagName -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> FlagName -> m FlagName #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> FlagName -> m FlagName #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> FlagName -> m FlagName #

Ord FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Read FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Show FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

IsString FlagName #

mkFlagName

Since: 2.0.0.2

Instance details

Defined in Distribution.Types.GenericPackageDescription

Generic FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Associated Types

type Rep FlagName :: Type -> Type #

Methods

from :: FlagName -> Rep FlagName x #

to :: Rep FlagName x -> FlagName #

Binary FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

put :: FlagName -> Put #

get :: Get FlagName #

putList :: [FlagName] -> Put #

NFData FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

rnf :: FlagName -> () #

Pretty FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

pretty :: FlagName -> Doc #

Parsec FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

parsec :: CabalParsing m => m FlagName #

Text FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

disp :: FlagName -> Doc #

parse :: ReadP r FlagName #

type Rep FlagName # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

type Rep FlagName = D1 (MetaData "FlagName" "Distribution.Types.GenericPackageDescription" "Cabal-2.4.1.0-4t2ut7bCQNuEj8DDES6BZk" True) (C1 (MetaCons "FlagName" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 ShortText)))

mkFlagName :: String -> FlagName #

Construct a FlagName from a String

mkFlagName is the inverse to unFlagName

Note: No validations are performed to ensure that the resulting FlagName is valid

Since: 2.0.0.2

unFlagName :: FlagName -> String #

Convert FlagName to String

Since: 2.0.0.2

data FlagAssignment #

A FlagAssignment is a total or partial mapping of FlagNames to Bool flag values. It represents the flags chosen by the user or discovered during configuration. For example --flags=foo --flags=-bar becomes [("foo", True), ("bar", False)]

Instances
Eq FlagAssignment # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Ord FlagAssignment # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Read FlagAssignment #

Since: 2.2.0

Instance details

Defined in Distribution.Types.GenericPackageDescription

Show FlagAssignment #

Since: 2.2.0

Instance details

Defined in Distribution.Types.GenericPackageDescription

Generic FlagAssignment # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Associated Types

type Rep FlagAssignment :: Type -> Type #

Semigroup FlagAssignment # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Monoid FlagAssignment # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Binary FlagAssignment # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

NFData FlagAssignment # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

rnf :: FlagAssignment -> () #

type Rep FlagAssignment # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

type Rep FlagAssignment = D1 (MetaData "FlagAssignment" "Distribution.Types.GenericPackageDescription" "Cabal-2.4.1.0-4t2ut7bCQNuEj8DDES6BZk" True) (C1 (MetaCons "FlagAssignment" PrefixI True) (S1 (MetaSel (Just "getFlagAssignment") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Map FlagName (Int, Bool)))))

mkFlagAssignment :: [(FlagName, Bool)] -> FlagAssignment #

Construct a FlagAssignment from a list of flag/value pairs.

If duplicate flags occur in the input list, the later entries in the list will take precedence.

Since: 2.2.0

unFlagAssignment :: FlagAssignment -> [(FlagName, Bool)] #

Deconstruct a FlagAssignment into a list of flag/value pairs.

 null (findDuplicateFlagAssignments fa) ==> (mkFlagAssignment . unFlagAssignment) fa == fa

Since: 2.2.0

lookupFlagAssignment :: FlagName -> FlagAssignment -> Maybe Bool #

Lookup the value for a flag

Returns Nothing if the flag isn't contained in the FlagAssignment.

Since: 2.2.0

insertFlagAssignment :: FlagName -> Bool -> FlagAssignment -> FlagAssignment #

Insert or update the boolean value of a flag.

If the flag is already present in the FlagAssigment, the value will be updated and the fact that multiple values have been provided for that flag will be recorded so that a warning can be generated later on.

Since: 2.2.0

diffFlagAssignment :: FlagAssignment -> FlagAssignment -> FlagAssignment #

Remove all flag-assignments from the first FlagAssignment that are contained in the second FlagAssignment

NB/TODO: This currently only removes flag assignments which also match the value assignment! We should review the code which uses this operation to figure out if this it's not enough to only compare the flagnames without the values.

Since: 2.2.0

findDuplicateFlagAssignments :: FlagAssignment -> [FlagName] #

Find the FlagNames that have been listed more than once.

Since: 2.2.0

nullFlagAssignment :: FlagAssignment -> Bool #

Test whether FlagAssignment is empty.

Since: 2.2.0

showFlagValue :: (FlagName, Bool) -> String #

String representation of a flag-value pair.

dispFlagAssignment :: FlagAssignment -> Doc #

Pretty-prints a flag assignment.

parseFlagAssignment :: ReadP r FlagAssignment #

Parses a flag assignment.

data ConfVar #

A ConfVar represents the variable type used.

Instances
Eq ConfVar # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

(==) :: ConfVar -> ConfVar -> Bool #

(/=) :: ConfVar -> ConfVar -> Bool #

Data ConfVar # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ConfVar -> c ConfVar #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ConfVar #

toConstr :: ConfVar -> Constr #

dataTypeOf :: ConfVar -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c ConfVar) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ConfVar) #

gmapT :: (forall b. Data b => b -> b) -> ConfVar -> ConfVar #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ConfVar -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ConfVar -> r #

gmapQ :: (forall d. Data d => d -> u) -> ConfVar -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> ConfVar -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> ConfVar -> m ConfVar #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ConfVar -> m ConfVar #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ConfVar -> m ConfVar #

Show ConfVar # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Generic ConfVar # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Associated Types

type Rep ConfVar :: Type -> Type #

Methods

from :: ConfVar -> Rep ConfVar x #

to :: Rep ConfVar x -> ConfVar #

Binary ConfVar # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

put :: ConfVar -> Put #

get :: Get ConfVar #

putList :: [ConfVar] -> Put #

NFData ConfVar # 
Instance details

Defined in Distribution.Types.GenericPackageDescription

Methods

rnf :: ConfVar -> () #

type Rep ConfVar # 
Instance details

Defined in Distribution.Types.GenericPackageDescription