ghc-lib-0.20201101: The GHC API, decoupled from GHC versions
Safe HaskellNone
LanguageHaskell2010

GHC.Iface.Ext.Binary

Synopsis

Documentation

readHieFile :: NameCacheUpdater -> FilePath -> IO HieFileResult Source #

Read a HieFile from a FilePath. Can use an existing NameCache.

readHieFileWithVersion :: (HieHeader -> Bool) -> NameCacheUpdater -> FilePath -> IO (Either HieHeader HieFileResult) Source #

Read a HieFile from a FilePath. Can use an existing NameCache. Allows you to specify which versions of hieFile to attempt to read. Left case returns the failing header versions.

writeHieFile :: FilePath -> HieFile -> IO () Source #

Write a HieFile to the given FilePath, with a proper header and symbol tables for Names and FastStrings

data HieName Source #

Name's get converted into HieName's before being written into .hie files. See toHieName and fromHieName for logic on how to convert between these two types.

Instances

Instances details
Eq HieName Source # 
Instance details

Defined in GHC.Iface.Ext.Types

Methods

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

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

Ord HieName Source # 
Instance details

Defined in GHC.Iface.Ext.Types

Outputable HieName Source # 
Instance details

Defined in GHC.Iface.Ext.Types

Methods

ppr :: HieName -> SDoc

hieMagic :: [Word8] Source #

The header for HIE files - Capital ASCII letters "HIE".

newtype NameCacheUpdater Source #

A function that atomically updates the name cache given a modifier function. The second result of the modifier function will be the result of the IO action.

Constructors

NCU 

Fields