IP Pascal - Modular Structure

Modular Structure

IP Pascal uses a unique stacking concept for modules. Each module is stacked one atop the other in memory, and executed at the bottom. The bottom module calls the next module up, and that module calls the next module, and so on.

wrapper serlib program cap

The cap module (sometimes called a "cell" in IP Pascal terminology, after a concept in integrated circuit design) terminates the stack, and begins a return process that ripples back down until the program terminates. Each module has its startup or entry section performed on the way up the stack, and its finalization or exit section performed on the way back down.

This matches the natural dependencies in a program. The most primitive modules, such as the basic I/O support in "serlib", perform their initialization first, and their finalization last, before and after the higher level modules in the stack.

Read more about this topic:  IP Pascal

Famous quotes containing the word structure:

    Slumism is the pent-up anger of people living on the outside of affluence. Slumism is decay of structure and deterioration of the human spirit. Slumism is a virus which spreads through the body politic. As other “isms,” it breeds disorder and demagoguery and hate.
    Hubert H. Humphrey (1911–1978)