|
New-Line-Is Section
GPP allows the developer to define a special new-line symbol (character), which can be used in OUTPUT statements throughout the program. Each time this new-line character is encountered as an OUTPUT argument, the new-line-is block is executed.
The new-line-is block is not mandatory in a GPP program. However, it must be defined if a new-line character is used in any OUTPUT statement. No more than one such block is allowed in a GPP program file. It is recommended to locate it immediately after the declaration part.
The format of the new-line block is as follows:
NEW_LINE_IS <char>;
Sequence of execution statements
The new-line character must be a non-alphanumeric character, but not one that is used inside the GPP language (For example, +, *, =, > or < are not allowed). It can be one of the following characters:
$ ! @ # % ^ & { } | ~ ?
Example
NEW_LINE_IS $ ; // new-line character is $
OUTPUT \J "N" SEQ; // output new-line and sequence number
SEQ = SEQ + SEQINCR; // increment sequence number
|