1. ISPF is not a language.If you are referring to panel definition statements, ELSE uses indentation to control scope. Python does the same thing. I don't like it, but it is what it is.
2. SO/END blocks containing only a single statement are useful if you may be adding code in the future. It's a stylistic issue about which you will never achieve consensus. -- Shmuel (Seymour J.) Metz http://mason.gmu.edu/~smetz3 ________________________________________ From: IBM Mainframe Discussion List [IBM-MAIN@LISTSERV.UA.EDU] on behalf of Bob Bridges [robhbrid...@gmail.com] Sent: Sunday, June 7, 2020 2:35 PM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: COBOL Question The only language I can think of off-hand that doesn't require some sort of END to close a DO (I'm sure there are others) is ISPF. But, in REXX at least, I never use single-statement DOs. I see them all the time, and I don't get it. Like this: if x=0 then do x=x+1 end Or, more painfully: select when idx="T" then do countt=countt+1 end when idx="U" then do countu=countu+1 end when idx="V" then do countv=countv+1 end when idx="W" then do countw=countw+1 end otherwise do countx=countx+1 end end Why? If it were easier to read, I might sympathize. But it's harder, not easier. --- Bob Bridges, robhbrid...@gmail.com, cell 336 382-7313 /* It's a good thing Lincoln wrote the Gettysburg Address the year that he did, or else that "fourscore and seven years" part would have just been plain wrong. -Paul Paternoster */ -----Original Message----- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Paul Gilmartin Sent: Saturday, June 6, 2020 14:40 But in Rexx similarly, END is required even for a single-statement DO. Good for Rexx. I like strong closure. >--- On 6 Jun 2020 10:53:44 -0700, (Bob Bridges) wrote: >>Oh, you need an END-IF even for a single-statement IF? I forgot; I've been >>thinking in REXX too long. In that case you're close; I guess I really meant ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN