HANDBOOK / GENTLE PRIMER / Organizing Larger Projects /

# The Root Module

Exactly one module must contain a root definition that triggers the computation.

For example, a specification could be given by three modules: `Compiler`, `IR`, and `CodeGen`, where the module heading of `Compiler` is

       'module' Compiler

       'use'
          IR, CodeGen

The module `Compiler` can contain a definition

       'root'
          Program(-> P)
          Encode(P)

This specification is elaborated by first invoking `Program` declared in `Compiler`, and then `Encode` declared in `CodeGen`.