EasyManuals Logo

IBM TSO/E REXX User Manual

IBM TSO/E REXX
242 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #60 background imageLoading...
Page #60 background image
v Interrupt instructions, which tell the language processor to leave the exec entirely
or leave one part of the exec and go to another part, either permanently or
temporarily. The REXX interrupt instructions are:
EXIT
SIGNAL label
CALL label/RETURN
Using Conditional Instructions
There are two types of conditional instructions. IF/THEN/ELSE can direct the
execution of an exec to one of two choices. SELECT/WHEN/OTHERWISE/END can
direct the execution to one of many choices.
IF/THEN/ELSE Instructions
The examples of IF/THEN/ELSE instructions in previous chapters demonstrated the
two-choice selection. In a flow chart, this appears as follows:
As a REXX instruction, the flowchart example looks like:
IF expression THEN instruction
ELSE instruction
You can also arrange the clauses in one of the following ways to enhance
readability:
IF expression THEN
instruction
ELSE
instruction
or
IF expression
THEN
instruction
ELSE
instruction
When you put the entire instruction on one line, you must separate the THEN
clause from the ELSE clause with a semicolon.
IF expression THEN instruction; ELSE instruction
Generally, at least one instruction should follow the THEN and ELSE clauses. When
either clause has no instructions, it is good programming practice to include NOP
(no operation) next to the clause.
IF
expression
False True
ELSE THEN
instruction instruction
Controlling the Flow Within an Exec
42
z/OS V1R1.0 TSO/E REXX User’s Guide

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the IBM TSO/E REXX and is the answer not in the manual?

IBM TSO/E REXX Specifications

General IconGeneral
BrandIBM
ModelTSO/E REXX
CategoryComputer Hardware
LanguageEnglish

Related product manuals