Figure 1 shows a modular decomposition of a typical compiler. Each block represents a module that could be generated by one or more tools. For example, LEX and YACC can generate the structural analysis module from declarative specifications. All of the modules represented by the other four blocks can also be generated from specifications by existing tools. Ideally, all of these specifications would be declarative; in practice, some operational specifications are required.
The specifications and generation tools for the structural analysis module are well known. In the remainder of this section I will briefly discuss those for the remaining four modules.