-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/

-- | Expands type synonyms in Template Haskell ASTs
--   
--   Expands type synonyms in Template Haskell ASTs.
--   
--   As of version 0.4.9.0, this library is a small shim on top of
--   the applySubstitution/resolveTypeSynonyms functions
--   from th-abstraction, so you may want to consider using
--   th-abstraction instead.
@package th-expand-syns
@version 0.4.12.0

module Language.Haskell.TH.ExpandSyns

-- | Calls expandSynsWith with the default settings.
expandSyns :: Type -> Q Type

-- | Expands all type synonyms in the given type. Type families currently
--   won't be expanded (but will be passed through).
expandSynsWith :: SynonymExpansionSettings -> Type -> Q Type
data SynonymExpansionSettings

-- | Suppresses the warning that type families are unsupported.
noWarnTypeFamilies :: SynonymExpansionSettings

-- | Capture-free substitution
substInType :: (Name, Type) -> Type -> Type

-- | Capture-free substitution
substInCon :: (Name, Type) -> Con -> Con

-- | Make a list of names (based on the first arg) such that every name in
--   the result is distinct from every name in the second arg, and from the
--   other results
evades :: Data t => [Name] -> t -> [Name]

-- | Make a name (based on the first arg) that's distinct from every name
--   in the second arg
--   
--   Example why this is necessary:
--   
--   
--   type E x = forall y. Either x y
--   
--   ... expandSyns [t| forall y. y -> E y |]
--   
--   
--   The example as given may actually work correctly without any special
--   capture-avoidance depending on how GHC handles the ys, but in
--   any case, the input type to expandSyns may be an explicit AST using
--   mkName to ensure a collision.
evade :: Data d => Name -> d -> Name
instance GHC.Internal.Base.Monoid Language.Haskell.TH.ExpandSyns.SynonymExpansionSettings
instance GHC.Internal.Base.Semigroup Language.Haskell.TH.ExpandSyns.SynonymExpansionSettings
