![](/images/backgrounds/286549/hp-sunsoft-pascal-4-0-users-manual-549395109x1.png)
5
The program unit, inc_prog2.p | program inc_prog2; |
| %include "include2.h"; |
| procedure proc; extern; |
| begin |
| global := 1; |
| writeln('From MAIN, before PROC: ',global); |
| proc; |
| writeln('From MAIN, after PROC: ',global); |
| end. { proc } |
|
|
The module unit, inc_mod2.p | module inc_mod2; |
|
| define |
|
| global; |
|
| %include "include2.h"; |
|
| procedure proc; |
|
| begin |
|
| writeln('From PROC | : ',global); |
| global := global + 1; |
|
| end; { proc } |
|
|
|
|
The include file, include2.h | var |
global : extern integer;
Separate Compilation | 85 |