I did try it, and I agree with Gil, and would add that the whole EXPORT
facility is rather bizarre.
First, the SYSUT1 SYSIN received 'AFTER' for the &S symbol.  I suppose that
means it is substituted sometime after the JCL is interpreted.  Maybe it
was easiest to implement it this way (along with weird extra JCL inserts).

sas


On Fri, Sep 16, 2016 at 8:44 PM, Paul Gilmartin <
0000000433f07816-dmarc-requ...@listserv.ua.edu> wrote:

> On Fri, 16 Sep 2016 23:37:57 +0000, Frank Swarbrick wrote:
> >
> >Maybe this isn't a real enough situation to matter, but it seems odd to
> me.
> >    ...
> Also, I was astonished by the behavior of (try it!)
>
> //STEP     EXEC  PGM=IEBGENER
> //SYSIN     DD  *
> //SYSPRINT  DD  SYSOUT=(,)
> //*
> //  EXPORT SYMLIST=S
> //*
> //  SET S='Before'
> //SYSUT1    DD  *,SYMBOLS=JCLONLY
>     The value of S was set &S DD SYSUT1!?
> //*
> //  SET S='DURING'
> //SYSUT2    DD  SYSOUT=(,&S)  What's the writer?
> //  SET S='After'
> //*
> Experts tell me it's intuitive; I feel otherwise; they could have done
> better.
> The behavior is irritating when I try setting a symbol before calling a
> PROC
> and get unexpected results.
>
> -- gil
>
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
>



-- 
sas

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to