TNS/R Native Application Migration Guide

TAL to pTAL Conversion Tasks
TNS/R Native Application Migration Guide523745-001
5-2
In some cases, you can maintain one set of source code for both TAL and pTAL. See
Maintaining Common Source Code for TNS and Native Compilers on page 2-3 for
details.
This manual does not describe the language-specific tasks required to convert from
TAL to pTAL. For detailed TAL-to-pTAL conversion information, see the appropriate
manual in the pTAL documentation set:
The pTAL Conversion Guide and pTAL Reference Manual are exhaustive manuals,
numbering together over 1,000 pages. To convert the majority of TAL programs, it is
not necessary to read these manuals completely. Instead, you can follow these steps:
1. Read pTAL Guidelines for TAL Programmers to familiarize yourself with the
difference between TAL and pTAL.
2. Process your source files with the pTAL compiler syntax checking option set. The
syntax is:
PTAL / IN source-filename, OUT listing-filename / ;SYNTAX
See the pTAL Reference Manualfor details on running the pTAL compiler.
3. Examine the pTAL compiler output listings to determine the changes that you must
make to the source files. Lookup the items that require changes in the pTAL
Reference Manual and the pTAL Conversion Guide.
Example 5-1. pTAL Compiler Listing With Syntax Checking
PROC myproc;
BEGIN
INT I;
*** Error: ^
--> I is declared to have type INT(16), but is used later as WADDR
[error 01023].
INT .p1;
I := @p1;
Manual Description
pTAL Guidelines for TAL Programmers Describes how to write TAL code that can be
converted to pTAL with minimal changes. Lists
the major differences between TAL and pTAL.
pTAL Conversion Guide Describes the differences between TAL and
pTAL. Explains in detail how to covert TAL
programs to pTAL.
pTAL Reference Manual Describes the syntax of the pTAL language.
Explains how to run the pTAL compiler.