On Mon, 21 Apr 2008 15:44:20 -0500, Patrick O'Keefe wrote: > >Maybe I misunderstand what you would want REXX to do. > >If you're talking about some way of invoking an On-condition block, >REXX obviously has it: you SIGNAL or CALL the block's label. > >If you want to verify an exec's ability to handle an abend condition >if you haven't included an exception routine, uh, well, maybe you >should include the routine rather than determining how to pick >up the pieces after a failure. > My technique for picking up the pieces after a failure is to improve the code so that it no longer fails. A nonzero return code is not a failure. Reference to an uninitialized variable is a failure.
>If you want to determine which Error/Failure/Halt/Noalue/Syntax >conditions is raised by a particular miscoded statement you still have >to execute the miscoded statement (or reread the doc). > >I think I've missed what you want. > Thanks. Perhaps I need to moderate some of my ancient compulsions: I have _never_ coded a SIGNAL. Partly hangover from the 3 decades ago "GOTO considered harmful" days; partly from needing to read and sometimes maintain spaghetti code from programmers who branch around their programs using SIGNAL with wild abandon, including one who used SIGNAL for early exit from a deeply nested subroutine, and came to me for assistance when his data set grew to the point that the stack overflowed. (Conversely, I use, perhaps overuse ITERATE and LEAVE to some of the same ends that they abuse SIGNAL.) And SIGNAL mixes with CALL and DO like oil and water. I have rarely coded an On-condition block, partly from resentment of the technique of one of the above programmers who always codes, roughly: signal on syntax ... syntax: say 'Syntax error at line' sigl exit 99 ... thereby providing less diagnostic information than the default Rexx traceback. But he believed that it was necessary to code a handler for every possible exception condition. I start every Rexx EXEC with "SIGNAL ON NOVALUE"; I never code a NOVALUE handler. I understand that nowadays there are instructions I can use in the handler to diagnose better and identify which variable caused the problem. I need to master those. But a "SIGNAL ERROR" with no handler would provide much the traceback and termination I desire. I'd just have to accept no longer being able to say "I have never coded a SIGNAL." (I also wish I could generate a Rexx traceback at some point, but continue execution.) Thanks, gil ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html