HP 3000 Manuals

S300_EXTNAMES [ HP Pascal/iX Reference Manual ] MPE/iX 5.0 Documentation


HP Pascal/iX Reference Manual

S300_EXTNAMES 

S300_EXTNAMES is an HP Pascal Option.

The S300_EXTNAMES compiler option specifies that the external names of
procedures in modules are of the form modulename_procedurename.

Syntax 

$S300_EXTNAMES {ON }$
               {OFF}

Default       OFF.

Location      Before the EXPORT part of a module.

The S300_EXTNAMES option tells the linker to use the external name
modulename_procedurename instead of procedurename when linking a program.
The name modulename_procedurename is in lowercase letters (as far as the
linker is concerned) unless the procedure was compiled with the compiler
option UPPERCASE ON.

The S300_EXTNAMES option applies to the entire module, but not to other
modules in the same compilation unit.  If a compilation unit contains
several such modules, each one must contain the S300_EXTNAMES option.

The purpose of this option is to allow non-Pascal source code that calls
external procedures that are in a Pascal module to be ported from, or be
common with, HP9000 Series 300 source code, without changing the source
code.  The HP9000 Series 300 prefixes modulename_ to procedurename in
forming the link name; HP Pascal does not.

Example 

     MODULE M1;
     $S300_EXTNAMES ON$
     EXPORT
        VAR
           V1 : INTEGER;
           PROCEDURE P1 (P : CHAR);
     IMPLEMENT
        .
        .
        .
     END;

     MODULE M2;
     EXPORT
        VAR
           V2 : INTEGER;
           PROCEDURE P2 (P : INTEGER);
     IMPLEMENT
        .
        .
        .
     END;

The external names for V1, P1, V2, and P2 are M1_V1, M1_P1, V2, and P2,
respectively.



MPE/iX 5.0 Documentation