Skip to content

Split GHC(-API) into multiple packages

Current GHC-API is pretty monolithic and a lot of data is hidden in monads. I'd prefer to have cleanly separated packages for parser, module system, type-checker, optimizer, code generator, linker. E.g. Haddock would certainly only use the first two, maybe three, steps. Advanced editing features in an IDE would use only the first three steps. A compiler for a Haskell dialect might use only optimizer and code generator. The packages should have clean interfaces. E.g. it should be possible to enter a Text or String into the parser and get a ByteString containing code or a pointer to executable code in memory from the code generator, with no need to write temporary files.

Trac metadata
Trac field Value
Version
Type Task
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information