On Mon, 26 May 2014 23:15:19 -0400, Robert A. Rosenberg wrote:
>At 11:47 -0700 on 05/26/2014, Charles Mills wrote about Passing lower
>case data on MODIFY:
>
>>I don't see anything in the MODIFY or EXTRACT documentation (other than
>>information specific to System Rexx). (I'm sure someone will be happy to
>>point it out if I missed something <g>.) I'd like to confirm what I am
>>observing to make sure it is not some bug or mis-observation of my own. It
>>appears to me that
>>
>>F taskname,foo results in FOO being passed to the program.
>>
>>F taskname,'foo' results in 'foo' being passed to the program.
>>
>>Is there any way to just pass foo -- lower case, no quotes -- on a MODIFY
>>command? (I don't mind the quotes in the syntax; I can readily live with
>>that; it's the passing of the quotes into the program that is currently
>>fouling me up.)
>>
>>(Taskname is a z/OS started task.)
>
>A couple of questions.
>
>1) Will the passed parm have imbedded blanks or will it be a single
>string of characters?
>
>2) Can there be any imbedded quotes in the parm?
>
>To fix #1, check if the first character is a quote. If so, then pass
>starting from the second character and do not pass the last character
>(the ending quote). So long as you pass a length, any imbedded blank
>should not be an issue.
>
>As to #2, after removing any bracketing quotes, you can either pass
>the doubled single quotes or parse and rebuild the parm by converting
>the doubled quotes to a single occurrence.
>
I'm not sure whom you're addressing when you use the second
person there, or if you're just mising Charle's point entirely. He
wants to be able to pass to the started task the three characters:
foxtrot, oscar, oscar. he does not want to pass to the started
task five characters: apostrophe, foxtrot, oscar, oscar, apostrophe
and modify the code of the started task to deal with the apostrophes.
I think your mind has been damaged by some extraordinarily
poor design of HLASM (perhaps inherited from older translators),
to the point where you consider it rational operation. Consider
(I think I have this correct):
&X SETC 'foo'
... sets &X to three characters (as above), but:
MYMACRO &X='foo'
... passes &X as five characters. Wretchedly inconsistent. JWG,
for example, is proud of his ability to write parsers in conditional
assembly language to deal with this mickeymouse. It shouldn't
be necessary.
-- gil
>----------------------------------------------------------------------
>For IBM-MAIN subscribe / signoff / archive access instructions,
>send email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN