On Sun, 20 Jun 2021 18:08:39 +0100, Jeremy Nicoll wrote:
>> >
>> I see.  I'd be inclined to code the repetitive part of that as a loop.
>
>There'd be no gain in converting the 8 separate named-for-what-they do 
>variables
>into stem variables if that's what you mean, unless one also defined _bfe, 
>_ssn etc
>as separate subscripts.  The vars are in fact the parameters to the function, 
>originally
>set via
>
I was imagining somethint like (untested; no stems):
    List = "ssn ssx stm wcn wcx wln wlx wld"
    do while List<>""
        if \datatype("f!ce_"L, "W") then f!ce_err = L value( "f!ce_"L ) "not a 
whole number"
        /* etc.  */
    end

Do you want to report every error, or leave after the first one?
I wish Rexx supported multi-line strings.

I wish Rexx would let me:
    do List = "ssn ssx stm wcn wcx wln wlx wld" while List<>""
        parse var List L List
        /* etc.  */

>> SIGNAL?  I suppose it's OK here.
>
>Thank-you, that's big of you.  It's a branch to the end of the function, so
>that there's only one place where control returns to the caller.
>    ...
>I only use signal in error handling / immediate exit/return situations.
>
And its value is in branching to common termination code before EXIT

I'm as compulsive about avoiding SIGNAL as you are aboutt singlee EXIT.
I might even wrap everything in an outer DO just so I could use LEAV.

-- gil

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to