On 12/05/2018 6:23 AM, Tony Thigpen wrote:
Come comments on other posts:
David Crayford wrote on 05/11/2018 02:22 PM:
> The fact that REXX does not have native support for VSAM
> data sets is a shocking omission.
This is available on s/VSE.
z/VM and z/VSE seem to have lots of features that z/OS lacks, like pipes.
David Crayford wrote on 05/11/2018 02:22 PM:
> Lack of variable scoping is one of my biggest gripes. It means
> REXX doesn't scale. Of course, you can add "procedure expose"
> to functions but that soon turns into an intractable mess.
I disagree. This sounds more like you are trying to use programming
habits/methods designed for another language. Any programming
'language' should be used as it was designed, not as some other
'language' was designed. Are you trying to make REXX look like Perl,
Java, PHP or bash?
Not at all! My opinion is based upon 30+ years of using REXX. The
inability to pass aggregate types (objects) in REXX (stem variables) to
functions makes it unsuitable for large programs. This is especially
true for external functions.
REXX also lacks modules or packages so reusing code is hard. The "expose
stem." construct doesn't cut it IMO. Once the code grows large it takes
a lot of mental gymnastics to remember what's been exposed. Lexical
scoping is
an absolute must in modern programming languages.
David Crayford wrote on 05/11/2018 02:28 PM:
> Perl excels at one thing, regular expressions. Its syntax is ugly
> and it suffers from language bloat.
I equate regular expressions with vi. It takes a lot of use to get
where you can use it without looking things up, and if you get to that
point, you have lived a hard life. :-)
I have to admit that the parse instruction in REXX is elegant and one of
it's redeeming features. But it lacks the power of regular expressions.
I missed regular expressions in REXX so much I wrote a command processor
[1].
Extending REXX is difficult and requires writing assembler code. In the
case of my regex API I needed to use CEEPIPI to glue together the
assembler code and LE C++ code. Extending languages like Python, Ruby,
Lua, Node.js
is trivial in comparison. But of course the language bindings for those
languages are written in C/C++, which is ok for me as I know those
languages.
[1] https://github.com/daveyc/RTK
David Crayford wrote on 05/11/2018 02:30 PM:
> I'm at a loss as to why anybody would use OOREXX on platforms where
> there are a multitude of better languages to chose from. If it's
> because of familiarity coming from z/OS or z/VM then I would
> advise them to take the time to learn something new. Most modern
> scripting languages can be picked up in less then a day.
And the code produced is usually crap for the first 5,000 or 10,000
lines of code written in a new language. I had rather know a few
languages well than many languages 'so-so'. Bringing your existing
skills into play is always a good thing. Bringing your poor skills
into play for a production code is just stupid. (I am not against
using your poorer skills for one-off, one-time use code. That is the
best place to learn new skills.)
But with modern languages you have to write less code. There are
libraries to do just about everything you can imagine. I was reading
about the new web services for REXX to create JSON. It really did hammer
home
just how difficult it is to do things in REXX that is one line of code
in modern languages. And to install libraries in modern languages you
use an installer like pip, gem, npm, luarocks which takes care of
dependencies etc.
It's a cliche but if the only tool you have is a hammer the whole world
looks like a nail.
After all the cut-n-paste, I noticed that the biggest complainer is
David. That's ok. You hate Rexx, I hate 'C', and Perl and PHP and ....
I hate Perl and PHP too. I'm not a fan of Ruby either. I don't much like
C but it's a useful language to know.
I have been accused before on this list of pathologically hating REXX.
That's not true, I appreciate it for what it's good at. But I have found
over the years that I prefer other languages. I'm a software developer
and write
code for a living so having the best tools available is important to me.
Tony Thigpen
----------------------------------------------------------------------
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