COBOL Manual for TNS and TNS/R Programs
Program Compilation
HP COBOL Manual for TNS and TNS/R Programs—522555-006
11-104
PORT and NOPORT
PORT and NOPORT
PORT and NOPORT determine:
•
How BINARY/COMPUTATIONAL data items are aligned
•
Whether the CALL statement in a program running in the CRE behaves as defined
in X/Open and XPG4 specification.
PORT
aligns BINARY/COMPUTATIONAL data items on byte boundaries (unless they are
described with the SYNCHRONIZED clause, which aligns them on 2-byte
boundaries).
PORT also allows the CALL statement in a program running in the CRE to behave
as it does in X/Open and XPG4; that is, to call non-COBOL routines, pass
parameters by value, and return the values of functions.
1
•
Allows CALL to call programs other than COBOL programs
•
Prevents the compiler from issuing a warning when the Linkage Section
does not having a matching item in the PROCEDURE DIVISION header
•
Causes the external variable RETURN-CODE to be automatically defined
2
prevents binary items from being aligned on word boundaries.
3
does what both PORT 1 and PORT 2 do. PORT 3 is equivalent to PORT.
NOPORT
aligns BINARY/COMPUTATIONAL data items according to standard alignment
rules and prevents the CALL statement in a program running in the CRE from
calling non-COBOL routines, passing parameters by value, and returning the
values of functions.
PORT
NOPORT
1
2
3
VST600.vsd