Safe Haskell | None |
---|---|
Language | Haskell98 |
This module contains a wrappers and utility functions for accessing GHC module information. It should NEVER depend on ANY module inside the Language.Haskell.Liquid.* tree.
- mkAlive :: Var -> Id
- data MGIModGuts = MI {
- mgi_binds :: !CoreProgram
- mgi_module :: !Module
- mgi_deps :: !Dependencies
- mgi_dir_imps :: ![ModuleName]
- mgi_rdr_env :: !GlobalRdrEnv
- mgi_tcs :: ![TyCon]
- mgi_fam_insts :: ![FamInst]
- mgi_exports :: !NameSet
- mgi_cls_inst :: !(Maybe [ClsInst])
- miModGuts :: Maybe [ClsInst] -> ModGuts -> MGIModGuts
- mg_dir_imps :: ModGuts -> [ModuleName]
- mgi_namestring :: MGIModGuts -> String
- srcSpanTick :: Module -> SrcSpan -> Tickish a
- tickSrcSpan :: Outputable a => Tickish a -> SrcSpan
- stringTyVar :: String -> TyVar
- stringVar :: String -> Type -> Var
- stringTyCon :: Char -> Int -> String -> TyCon
- stringTyConWithKind :: Kind -> Char -> Int -> String -> TyCon
- hasBaseTypeVar :: Var -> Bool
- isBaseType :: Type -> Bool
- validTyVar :: String -> Bool
- tvId :: TyVar -> String
- tidyCBs :: [CoreBind] -> [CoreBind]
- unTick :: CoreBind -> CoreBind
- unTickExpr :: CoreExpr -> CoreExpr
- isFractionalClass :: Class -> Bool
- tracePpr :: Outputable a => String -> a -> a
- pprShow :: Show a => a -> SDoc
- toFixSDoc :: Fixpoint a => a -> Doc
- sDocDoc :: SDoc -> Doc
- pprDoc :: Outputable a => a -> Doc
- showPpr :: Outputable a => a -> String
- showSDoc :: SDoc -> String
- myQualify :: PrintUnqualified
- showSDocDump :: SDoc -> String
- typeUniqueString :: Outputable a => a -> String
- newtype Loc = L (Int, Int)
- fSrcSpan :: Loc a => a -> SrcSpan
- fSrcSpanSrcSpan :: SrcSpan -> SrcSpan
- srcSpanFSrcSpan :: SrcSpan -> SrcSpan
- sourcePos2SrcSpan :: SourcePos -> SourcePos -> SrcSpan
- sourcePosSrcSpan :: SourcePos -> SrcSpan
- sourcePosSrcLoc :: SourcePos -> SrcLoc
- srcSpanSourcePos :: SrcSpan -> SourcePos
- srcSpanSourcePosE :: SrcSpan -> SourcePos
- srcSpanFilename :: SrcSpan -> String
- srcSpanStartLoc :: RealSrcSpan -> Loc
- srcSpanEndLoc :: RealSrcSpan -> Loc
- oneLine :: RealSrcSpan -> Bool
- lineCol :: RealSrcSpan -> (Int, Int)
- realSrcSpanSourcePos :: RealSrcSpan -> SourcePos
- realSrcSpanSourcePosE :: RealSrcSpan -> SourcePos
- getSourcePos :: NamedThing a => a -> SourcePos
- getSourcePosE :: NamedThing a => a -> SourcePos
- locNamedThing :: NamedThing a => a -> Located a
- namedLocSymbol :: (Symbolic a, NamedThing a) => a -> Located Symbol
- varLocInfo :: (Type -> a) -> Var -> Located a
- collectArguments :: Int -> CoreExpr -> [Var]
- collectTyBinders :: CoreExpr -> ([Var], CoreExpr)
- collectValBinders' :: Expr Var -> ([Var], Expr Var)
- ignoreLetBinds :: Expr t -> Expr t
- isTupleId :: Id -> Bool
- idDataConM :: Id -> Maybe DataCon
- isDataConId :: Id -> Bool
- getDataConVarUnique :: Var -> Unique
- isDictionaryExpression :: Expr Id -> Maybe Id
- realTcArity :: TyCon -> Arity
- kindArity :: Kind -> Arity
- uniqueHash :: Uniquable a => Int -> a -> Int
- lookupRdrName :: HscEnv -> ModuleName -> RdrName -> IO (Maybe Name)
- qualImportDecl :: ModuleName -> ImportDecl name
- ignoreInline :: ParsedModule -> ParsedModule
- symbolTyConWithKind :: Kind -> Char -> Int -> Symbol -> TyCon
- symbolTyCon :: Char -> Int -> Symbol -> TyCon
- symbolTyVar :: Symbol -> TyVar
- localVarSymbol :: Var -> Symbol
- exportedVarSymbol :: Var -> Symbol
- qualifiedNameSymbol :: Name -> Symbol
- fastStringText :: FastString -> Text
- tyConTyVarsDef :: TyCon -> [TyVar]
- splitModuleName :: Symbol -> (Symbol, Symbol)
- dropModuleNamesAndUnique :: Symbol -> Symbol
- dropModuleNames :: Symbol -> Symbol
- takeModuleNames :: Symbol -> Symbol
- dropModuleUnique :: Symbol -> Symbol
- cmpSymbol :: Symbol -> Symbol -> Bool
- sepModNames :: Text
- sepUnique :: Text
- mungeNames :: (String -> [Text] -> Symbol) -> Text -> String -> Symbol -> Symbol
- qualifySymbol :: Symbol -> Symbol -> Symbol
- isQualified :: Text -> Bool
- wrapParens :: (IsString a, Monoid a) => a -> a
- isParened :: Text -> Bool
- isDictionary :: Symbolic a => a -> Bool
- isInternal :: Symbolic a => a -> Bool
- stripParens :: Text -> Text
- stripParensSym :: Symbol -> Symbol
- desugarModule :: TypecheckedModule -> Ghc DesugaredModule
- gHC_VERSION :: String
- symbolFastString :: Symbol -> FastString
- type Prec = TyPrec
- lintCoreBindings :: [Var] -> CoreProgram -> (Bag MsgDoc, Bag MsgDoc)
- synTyConRhs_maybe :: TyCon -> Maybe Type
- tcRnLookupRdrName :: HscEnv -> Located RdrName -> IO (Messages, Maybe [Name])
- showCBs :: Bool -> [CoreBind] -> String
- findVarDef :: Symbol -> [CoreBind] -> Maybe (Var, CoreExpr)
- coreBindSymbols :: CoreBind -> [Symbol]
- simplesymbol :: NamedThing t => t -> Symbol
- binders :: Bind a -> [a]
Documentation
data MGIModGuts Source #
Datatype For Holding GHC ModGuts ------------------------------------------
MI | |
|
mg_dir_imps :: ModGuts -> [ModuleName] Source #
mgi_namestring :: MGIModGuts -> String Source #
srcSpanTick :: Module -> SrcSpan -> Tickish a Source #
Encoding and Decoding Location --------------------------------------------
tickSrcSpan :: Outputable a => Tickish a -> SrcSpan Source #
stringTyVar :: String -> TyVar Source #
Generic Helpers for Accessing GHC Innards ---------------------------------
hasBaseTypeVar :: Var -> Bool Source #
isBaseType :: Type -> Bool Source #
validTyVar :: String -> Bool Source #
unTickExpr :: CoreExpr -> CoreExpr Source #
isFractionalClass :: Class -> Bool Source #
tracePpr :: Outputable a => String -> a -> a Source #
Pretty Printers -----------------------------------------------------------
pprDoc :: Outputable a => a -> Doc Source #
showPpr :: Outputable a => a -> String Source #
showSDocDump :: SDoc -> String Source #
typeUniqueString :: Outputable a => a -> String Source #
Manipulating Source Spans -------------------------------------------------
fSrcSpanSrcSpan :: SrcSpan -> SrcSpan Source #
srcSpanFSrcSpan :: SrcSpan -> SrcSpan Source #
sourcePosSrcSpan :: SourcePos -> SrcSpan Source #
sourcePosSrcLoc :: SourcePos -> SrcLoc Source #
srcSpanSourcePos :: SrcSpan -> SourcePos Source #
srcSpanSourcePosE :: SrcSpan -> SourcePos Source #
srcSpanFilename :: SrcSpan -> String Source #
srcSpanStartLoc :: RealSrcSpan -> Loc Source #
srcSpanEndLoc :: RealSrcSpan -> Loc Source #
oneLine :: RealSrcSpan -> Bool Source #
getSourcePos :: NamedThing a => a -> SourcePos Source #
getSourcePosE :: NamedThing a => a -> SourcePos Source #
locNamedThing :: NamedThing a => a -> Located a Source #
namedLocSymbol :: (Symbolic a, NamedThing a) => a -> Located Symbol Source #
collectArguments :: Int -> CoreExpr -> [Var] Source #
Manipulating CoreExpr -----------------------------------------------------
ignoreLetBinds :: Expr t -> Expr t Source #
isTupleId :: Id -> Bool Source #
Predicates on CoreExpr and DataCons ---------------------------------------
isDataConId :: Id -> Bool Source #
getDataConVarUnique :: Var -> Unique Source #
realTcArity :: TyCon -> Arity Source #
lookupRdrName :: HscEnv -> ModuleName -> RdrName -> IO (Maybe Name) Source #
qualImportDecl :: ModuleName -> ImportDecl name Source #
symbolTyConWithKind :: Kind -> Char -> Int -> Symbol -> TyCon Source #
Symbol Conversions --------------------------------------------------------
symbolTyVar :: Symbol -> TyVar Source #
localVarSymbol :: Var -> Symbol Source #
exportedVarSymbol :: Var -> Symbol Source #
qualifiedNameSymbol :: Name -> Symbol Source #
fastStringText :: FastString -> Text Source #
tyConTyVarsDef :: TyCon -> [TyVar] Source #
splitModuleName :: Symbol -> (Symbol, Symbol) Source #
Manipulating Symbols ------------------------------------------------------
dropModuleNamesAndUnique :: Symbol -> Symbol Source #
dropModuleNames :: Symbol -> Symbol Source #
takeModuleNames :: Symbol -> Symbol Source #
dropModuleUnique :: Symbol -> Symbol Source #
sepModNames :: Text Source #
qualifySymbol :: Symbol -> Symbol -> Symbol Source #
isQualified :: Text -> Bool Source #
wrapParens :: (IsString a, Monoid a) => a -> a Source #
isDictionary :: Symbolic a => a -> Bool Source #
isInternal :: Symbolic a => a -> Bool Source #
stripParens :: Text -> Text Source #
stripParensSym :: Symbol -> Symbol Source #
gHC_VERSION :: String Source #
GHC Compatibility Layer ---------------------------------------------------
symbolFastString :: Symbol -> FastString Source #
lintCoreBindings :: [Var] -> CoreProgram -> (Bag MsgDoc, Bag MsgDoc) Source #
coreBindSymbols :: CoreBind -> [Symbol] Source #
simplesymbol :: NamedThing t => t -> Symbol Source #
Orphan instances
Show Class Source # | |
Show Var Source # | |
Show TyCon Source # | |
Show Name Source # | |
NFData Class Source # | |
NFData Var Source # | |
NFData TyCon Source # | |
NFData Type Source # | |
Hashable Var Source # | |
Hashable TyCon Source # | |
Hashable SrcSpan Source # | |
Fixpoint Var Source # | |
Fixpoint Type Source # | |
Fixpoint Name Source # | |
Symbolic Class Source # | |
Symbolic Var Source # |
|
Symbolic TyCon Source # | Symbol Instances |
Symbolic FastString Source # | |
Symbolic Name Source # | |
Outputable a => Outputable (HashSet a) Source # | |