I appreciate the fact based reply. I spent 3 months reworking a
legacy COBOL
application recently. I had a lot of time to reflect on why the code
I was
working on was so hard to follow and modify. It was out of that
morass of
crap code that I developed my theory of the virtue of parameters and
the
evil of the global variable.
-Steve
Fair enough.
And sorry for jumping rather on the defence myself. I've been battling
my own issues with others - which often revolves around people trying to
use a bulldozer to dig for a china cup (yeah, I stole that from Raiders
of the Lost Ark) - or in other words always using the same approach
(language choice or structure) to resolve very different problems - even
when their choice is obviously not 'fitting' well.
I don't think there ever will be a best or worse language. Each can be
abused, each has it's own strengths and it's own weaknesses. I'm in
support of clear maintainable code in all languages, and I think the
technique of organized code transcends the language (to an extent).
Your main original point is well taken - those languages that limit or
omit variable scoping do indeed add an extra maintenance issue that can
easily be a problem. Variable scoping is a good thing when used
properly, and sub procedures provide that nicely in RPG. The omission of
variable scoping in some languages such as COBOL is a limitation that
needs to be weighed when choosing those tools.
Cheers
Jim
This message has been sent from Foodstuffs (Auckland) Limited ("Foodstuffs").
The information contained in this message and or attachments
is intended only for the person or entity to which it is
addressed and may contain confidential and/or privileged
material. Any review, retransmission, dissemination or other
use of, or taking of any action in reliance upon, this
information by persons or entities other than the intended
recipient is prohibited. If you received this in error,
please contact the sender and delete the material from any
system and destroy any copies.
The views and opinions expressed in this message may be those
of the individual and not necessarily those of Foodstuffs,
and are not given or endorsed by it.
Please note that this communication does not designate an
information system for the purposes of the Electronic
Transactions Act 2002.
As an Amazon Associate we earn from qualifying purchases.