× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



M. Lazarus wrote:
 We have heard on this list several times that RPG is not a good language
to become an OO language.  You also mentioned a few reasons, but those
leaned more toward preference than technical obstacles.

 What technical obstacles do you see?  And what *serious* programming
obstacles do you see?  (For example, I do not consider strong typing to be
a serious obstacle, because that could be relaxed in some instances [CONST
parms being an  example of that], or, as you mentioned, the design s/b
revisited.)
Good questions!

Technically, I don't think there are any *major* obstacles. I think
the main problems would be in defining an OO language to the
satisfaction of its users, within a budget that was acceptable to
IBM management.

This all really depends on what kind of object model you want. Right
now, the language has references to Java objects. Perhaps the
language could be enhanced with syntax that makes the use of Java
objects easier? Like Java, we could have a language with two types
of things: Objects, and the native RPG data types. This would allow
us full upward compatibility with existing RPG code.

Now then, using objects defined in Java with a more OO-style syntax
probably would be fairly straight-forward. This would make a lot of
sense since we then wouldn't have to re-invent the whole class
hierarchy of Java, which contains a heck of a lot of useful
functionality.

Defining classes in RPG would probably be more difficult to design
and implement. And it would probably end up looking and working
pretty much like Java.

So, what exactly is gained by this type of design? Would this be any
easier than, say, just learning Java? Probably not since the biggest
aspect of learning Java is learning how to use the Java class
library. And learning OO methodology would still be required, which
of course is a pre-requisite to using any OO language.

Which brings me back to my original point. If you want to do OO
programming, use an OO language, from which there are already many
good ones to choose.

Alternatively, learn OO using a language suited to learning (such as
Python), and then apply your new skills in RPG. I've previously
argued that learning OO can improve your skills, even in procedural
programming.

Cheers!  Hans





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.