× 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.



There was a technique used before service programs arrived - and even afterwards, perhaps - to use a pair of /copy members, the first as a header, the 2nd as executable code at the end of a source member.

I do not say it is a desirable way to work, but you may run across this usage - it DOES make it possible to have maintainable utility code in one place, so you are not using copy/paste techniques, which are prone to all kinds of error of forgetting where it all is.

Now one downside - programs will all be larger than they need to be, if you have a service program with all those utility functions.

Once in place, such practices take time to bring forward to using more modern methods - time we don't always have.

All I've said lines up, I hope, with what John and the others have offered, though.

HTH
Vern

On 3/11/2015 8:42 PM, John Yeung wrote:
I agree with the prevailing responses you've already received.

A small thing I'd like to add regarding C and C++: Their include files
are typically called "header files" or simply "headers". This makes it
very clear that they're meant for prototypes and other setup, not
arbitrary code.

I am going to guess that there is a decent-sized minority of RPG
programmers who "grew up" with pre-ILE versions of RPG. I'm not going
to say that these are categorically bad programmers. I think some
percentage of them are "modularity minded", making extensive use of
subroutines and using manageable, reusable *PLIST-called OPM programs.
Granted, not as nice as subprocedures and service programs, but still
a far cry from what I would call "monolithic".

Now, the point of that verbose preamble is this: I think THOSE
programmers are the ones who are most opposed to copy blocks. Because
really, what are you going to do with copy blocks in OPM? They don't
really gain you very much in OPM, and they still have all the
disadvantages.

Full disclosure: I consider myself a modularity-minded OPM RPG
programmer, and our codebase where I work is almost exclusively
"modularly OPM RPG IV". C was my primary programming language
throughout high school and college; I never heard of RPG or AS/400
until my first job after graduating.

John Y.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.