ghc-lib-0.20190903: The GHC API, decoupled from GHC versions

Safe HaskellNone
LanguageHaskell2010

HsDumpAst

Contents

Description

Contains a debug function to dump parts of the hsSyn AST. It uses a syb traversal which falls back to displaying based on the constructor name, so can be used to dump anything having a Data.Data instance.

Synopsis

Dumping ASTs

showAstData :: Data a => BlankSrcSpan -> a -> SDoc Source #

Show a GHC syntax tree. This parameterised because it is also used for comparing ASTs in ppr roundtripping tests, where the SrcSpan's are blanked out, to avoid comparing locations, only structure

data BlankSrcSpan Source #

Instances
Eq BlankSrcSpan Source # 
Instance details

Defined in HsDumpAst

Show BlankSrcSpan Source # 
Instance details

Defined in HsDumpAst