TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Darin McBride
from: David Noon
date: 1996-01-09 20:42:00
subject: REXX syntax-checker

On Sunday, 96/01/07, Darin McBride wrote to David Noon about "REXX
syntax-checker" as follows:

DM>  DN> Since the variable RC is used by the REXX run-time to report the
DM>  DN> ERRORLEVEL of external commands, it is not always wise to use it
DM>  DN> as a program variable. Perhaps Ret_code, or some other non-system
DM>  DN> name might be more appropriate.
DM> 
DM> I believe that if you were to use 'call SysFunctionToTestError',
DM> and SysFunctionToTestError was in REXXUTIL, rc is set the same  as it
DM> shows above anyway.  I could be mistaken, but... if  I'm not, then
DM> there's no difference - it gets overwritten  anyway.

Hi Darin,

You are mistaken I'm afraid. The variable RESULT is the one that gets
modified when a function is CALLed and returns a result anyway. The
variable RC is used by the external subcommand handler to pass back an
ERRORLEVEL from an external command.

It is best programming practice to modify neither of them yourself.

Regards

Dave


 * KWQ/2 1.2i * I'm a Fidonut and I'm ok. I FREQ all night and I flame all day!

--- Maximus/2 3.01
* Origin: DoNoR/2,Woking UK (44-1483-725167) (2:440/4)
SEEN-BY: 50/99 270/101 620/243 711/401 409 410 413 430 808 809 934 955
SEEN-BY: 712/407 515 517 628 713/888 800/1 7877/2809
@PATH: 440/4 141/209 270/101 712/515 711/808 809 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.