Charles Mills wrote:
| PGM= is positional, is it not?
and this of course is a debater's point, but it is one I should have been
tempted to make too in response to a too sweeping "WTF?".
The first parameter following EXEC may be any one of
o PGM=<program name>,
o PROC=<procedure name>, or just
o <procedure name>.
This last default option is the problematic one.
Like the assignment statement in some statement-level procedural languages, an
instance of it it is most easily recognized as "not being an instance of some
other permitted thing", in this case a supported EXEC-statement keyword
parameter, here one of PGM= or PROC=.
Two design errors are thus conflated:
o treating GUBBINS as an instance of PROC=GUBBINS was the first, major blunder;
but
o judging that a scan that required only that positional parameters be kept in
sequence would be
too difficult to write or maintain was the second.
The HLASM, for example, permits the keyword and positional parameters of a
macro definition to be intermixed, with only the positional ones kept in
sequence. If, say, one writes
| macro
| EXAMPLE positional1,keyword1=,positional2,keyword2=,positional3
| . . .
| mend
in a macro definition, EXAMPLE macro instructions can take such forms as
| EXAMPLE
keyword2=<value2>,positional1,positional2,keyword1=<value2>,positional3
| EXAMPLE
keyword1=<value1>,positional1,keyword2=<value2>,positional2,positional3
The only requirement is that positional1 come before positional2, positional2
come before positional3, etc., in such a macro instruction. Keyword parameters
may be interspersed among them in any sequence.
It would now be difficult to sort out who took this decision or why it was
taken (if indeed it was ever taken explicitly); but JCL, in spite of its name,
was not really conceived of originally as a language having a formal syntax.
There is evidence that, circa 1963, it was thought of as nothing more than a
convenient set of coding conventions that could, again conveniently, be
borrowed from assembly language, which was of course very familiar to all of
the borrowers.
Coherence---The notion that knowledge of a subset of some language should make
plausible, almost invariably confirmed conjectures about its unknown facilities
possible---was not yet valued as it is or, better, should be today.
John Gilmore Ashland, MA 01721-1817 USA
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html