Author: Christian.Queinnec@lip6.fr

## To Learn More

The reference book on lexical analysis and parsing is known affectionately as the ``dragon book'', a reference to the book's cover illustration. Its real name is Compilers: principles, techniques and tools ([ASU86]). It covers all aspects of compiler design and implementation. It explains clearly the construction of automata matching a given context-free grammar and the techniques to minimize it. The tools `lex` and `yacc` are described in-depth in several books, a good reference being [LMB92]. The interesting features of `ocamllex` and `ocamlyac` with respect to their original versions are the integration of the Objective CAML language and, above all, the ability to write typed lexers and parsers. With regard to streams, the research report by Michel Mauny and Daniel de Rauglaudre [MdR92] gives a good description of the operational semantics of this extension. On the other hand, [CM98] shows how to build such an extension. For a better integration of grammars within the Objective CAML language, or to modify the grammars of the latter, we may also use the `camlp4` tool found at:

### Link

http://caml.inria.fr/camlp4/