A.1 Basics

As described in chapter 4, page 365, unit description files (hereafter called PPU files for short), are used to determine if the unit code must be recompiled or not. In other words, the PPU files act as mini-makefiles, which is used to check dependencies of the different code modules, as well as verify if the modules are up to date or not. Furthermore, it contains all public symbols defined for a module.

The general format of the ppu file format is shown in figure (A.1).



Figure A.1: The PPU file format

PIC


To read or write the ppufile, the ppu unit ppu.pas can be used, which has an object called tppufile which holds all routines that deal with ppufile handling. While describing the layout of a ppufile, the methods which can be used for it are presented as well.

A unit file consists of basically five or six parts:

  1. A unit header.
  2. A general information part (wrongly named interface section in the code)
  3. A definition part. Contains all type and procedure definitions.
  4. A symbol part. Contains all symbol names and references to their definitions.
  5. A browser part. Contains all references from this unit to other units and inside this unit. Only available when the uf_has_browser flag is set in the unit flags
  6. A file implementation part (currently unused).