GHC.Hs

ghc-9.0.0.20200925: The GHC API

Safe Haskell | None
Language | Haskell2010

GHC.Hs

Synopsis

- module GHC.Hs.Binds
- module GHC.Hs.Decls
- module GHC.Hs.Expr
- module GHC.Hs.ImpExp
- module GHC.Hs.Lit
- module GHC.Hs.Pat
- module GHC.Hs.Type
- module GHC.Hs.Utils
- module GHC.Hs.Doc
- module GHC.Hs.Extension
- data Fixity
- data HsModule = HsModule {
  - hsmodLayout :: LayoutInfo
  - hsmodName :: Maybe (Located ModuleName)
  - hsmodExports :: Maybe (Located [LIE GhcPs])
  - hsmodImports :: [LImportDecl GhcPs]
  - hsmodDecls :: [LHsDecl GhcPs]
  - hsmodDeprecMessage :: Maybe (Located WarningTxt)
  - hsmodHaddockModHeader :: Maybe LHsDocString
  }

# Documentation

module GHC.Hs.Binds

module GHC.Hs.Decls

module GHC.Hs.Expr

module GHC.Hs.ImpExp

module GHC.Hs.Lit

module GHC.Hs.Pat

module GHC.Hs.Type

module GHC.Hs.Utils

module GHC.Hs.Doc

module GHC.Hs.Extension

data Fixity Source #

#### Instances

Instances details

Eq Fixity # |
Instance details Defined in GHC.Types.Basic Methods (==) :: Fixity -> Fixity -> Bool # (/=) :: Fixity -> Fixity -> Bool #
Data Fixity # |
Instance details Defined in GHC.Types.Basic Methods gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Fixity -> c Fixity Source # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Fixity Source # toConstr :: Fixity -> Constr Source # dataTypeOf :: Fixity -> DataType Source # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Fixity) Source # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Fixity) Source # gmapT :: (forall b. Data b => b -> b) -> Fixity -> Fixity Source # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Fixity -> r Source # gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Fixity -> r Source # gmapQ :: (forall d. Data d => d -> u) -> Fixity -> [u] Source # gmapQi :: Int -> (forall d. Data d => d -> u) -> Fixity -> u Source # gmapM :: Monad m => (forall d. Data d => d -> m d) -> Fixity -> m Fixity Source # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Fixity -> m Fixity Source # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Fixity -> m Fixity Source #
Outputable Fixity # |
Instance details Defined in GHC.Types.Basic Methods ppr :: Fixity -> SDoc Source # pprPrec :: Rational -> Fixity -> SDoc Source #
Binary Fixity # |
Instance details Defined in GHC.Utils.Binary Methods put_ :: BinHandle -> Fixity -> IO () Source # put :: BinHandle -> Fixity -> IO (Bin Fixity) Source # get :: BinHandle -> IO Fixity Source #

data HsModule Source #

Haskell Module

All we actually declare here is the top-level structure for a module.

Constructors

HsModule |
Fields hsmodLayout :: LayoutInfo Layout info for the module. For incomplete modules (e.g. the output of parseHeader), it is NoLayoutInfo. hsmodName :: Maybe (Located ModuleName) `Nothing`: "module X where" is omitted (in which case the next field is Nothing too) hsmodExports :: Maybe (Located [LIE GhcPs]) Export list `Nothing`: export list omitted, so export everything `Just []`: export nothing `Just [...]`: as you would expect... `AnnKeywordId`s : `AnnOpen` ,`AnnClose` hsmodImports :: [LImportDecl GhcPs] We snaffle interesting stuff out of the imported interfaces early on, adding that info to TyDecls/etc; so this list is often empty, downstream. hsmodDecls :: [LHsDecl GhcPs] Type, class, value, and interface signature decls hsmodDeprecMessage :: Maybe (Located WarningTxt) reason/explanation for warning/deprecation of this module `AnnKeywordId`s : `AnnOpen` ,`AnnClose` hsmodHaddockModHeader :: Maybe LHsDocString Haddock module info and description, unparsed `AnnKeywordId`s : `AnnOpen` ,`AnnClose`

#### Instances

Instances details

Data HsModule # |
Instance details Defined in GHC.Hs Methods gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsModule -> c HsModule Source # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c HsModule Source # toConstr :: HsModule -> Constr Source # dataTypeOf :: HsModule -> DataType Source # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c HsModule) Source # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c HsModule) Source # gmapT :: (forall b. Data b => b -> b) -> HsModule -> HsModule Source # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsModule -> r Source # gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsModule -> r Source # gmapQ :: (forall d. Data d => d -> u) -> HsModule -> [u] Source # gmapQi :: Int -> (forall d. Data d => d -> u) -> HsModule -> u Source # gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsModule -> m HsModule Source # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsModule -> m HsModule Source # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsModule -> m HsModule Source #
Outputable HsModule # |
Instance details Defined in GHC.Hs Methods ppr :: HsModule -> SDoc Source # pprPrec :: Rational -> HsModule -> SDoc Source #