Changes between Version 9 and Version 10 of Commentary/Compiler/HscMain


Ignore:
Timestamp:
Sep 8, 2006 2:27:05 PM (8 years ago)
Author:
simonpj
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Commentary/Compiler/HscMain

    v9 v10  
    88Look at the picture first.  The yellow boxes are compiler passes, while the blue stuff on the left gives the data type that moves from one phase to the next.  The entire pipeline for a single module is run by a module called !HscMain (in GhcFile(compiler/main/HscMain)).  Here are the steps it goes through: 
    99 
    10  * The program is initially parsed into the {{{HsSyn}}} types (in the [[GhcFile(compiler/hsSyn)]] directory), a collection of data types that describe the full abstract syntax of Haskell.  {{{HsSyn}}} is a pretty big colleciton of types: there are 52 data types when I last counted.  Many are pretty trivial, but a few have a lot of constructors ({{{HsExpr}}} has 40).  {{{HsSyn}}} represents Haskell its full glory, complete with all syntactic sugar. 
     10 * The program is initially parsed into the [wiki:Commentary/Compiler/HsSynType big HsSyn type]. 
    1111 
    1212 * {{{HsSyn}}} is parameterised over the types of the variables it contains.  The first three passes (the front end) of the compiler work like this:[[BR]][[BR]]