IBM SC34-5764-01 Server User Manual


 
When the program runs, the language processor sends the following lines of output.
7 +++ PULL who /* Get the person's name.IF who =
'' THEN SAY 'Hello, stranger'ELSE SAY 'Hello,' who
CICREX453E Error 6 running HELLO EXEC, line 7: Unmatched "/*" or quote
The program runs until the language processor detects the error, the missing */ at the end of the
comment. The PULL instruction does not use the data from the data stack or terminal because this line
contains the syntax error. The program ends, and the language processor sends the error messages.
The first error message begins with the line number of the statement where the language processor
detected the error. Three pluses (+++) and the contents of the statement follow this.
7 +++ PULL who /* Get the person's name.IF who =
'' THEN SAY 'Hello, stranger' ELSE SAY 'Hello,' who
The second error message begins with the message number. A message containing the program name,
the line where the language processor found the error, and an explanation of the error follow this.
CICREX453E Error 6 running HELLO EXEC, line 7: Unmatched "/*" or quote
For more information about the error, you can go to the message explanations in Appendix A, “Error
Numbers and Messages,” on page 379.
To fix the syntax error in this program, add */ to the end of the comment on line 7.
PULL who /* Get the person's name. */
How to Prevent Translation to Uppercase
The language processor generally translates alphabetic characters to uppercase before processing them.
The alphabetic characters can be within a program, such as words in a REXX instruction, or they can be
external to a program and processed as input. You can prevent the translation to uppercase as follows:
Characters within a program
To prevent translation of alphabetic characters in a program to uppercase, simply enclose the characters in
single or double quotation marks. The language processor does not change numbers and special
characters, regardless of whether they are in quotation marks. Suppose you use a SAY instruction with a
phrase containing a mixture of alphabetic characters, numbers, and special characters; the language
processor changes only the alphabetic characters.
SAY The bill for lunch comes to £123.51!
results in:
THE BILL FOR LUNCH COMES TO £123.51!
(This example assumes none of the words are the names of variables that have been assigned other
values.)
/************************** REXX **********************************/
/* This REXX program contains a deliberate error of not closing */
/* a comment. Without the error, it would pull input to produce */
/* a greeting. */
/******************************************************************/
PULL who /* Get the person's name.
IF who = '' THEN
SAY 'Hello, stranger'
ELSE
SAY 'Hello,' who
Figure 5. Example of a program with a Syntax Error
Writing and Running a REXX Program
Chapter 2. Writing and Running a REXX Program 13