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



I can't say how common it is, but yes, others (including me) have noticed
this sort of 'magic' before. It's not always appreciated though. For
example I recently developed an RPGIV module onV5R3, using TRGRLS(*PRV),
that had to be compiled on V5R2 for production use. The module was tested,
including installing and running on a V5R2 partition. I thought using
TGTRLS(*PRV) would catch any unintentional use of V5R3 language
enhancements. Wrong! Of course, I had used V5R3 features that, of course,
could not be compiled onV5R2. This experience has refined by understanding
of the TGTRLS parameter. It insures the module can be run on the target
release but not necessarily compiled there.


On 4/3/07, qsrvbas@xxxxxxxxxxxx <qsrvbas@xxxxxxxxxxxx> wrote:

Here's a simple CL program:

pgm

dcl &uint *uint
dcl &int *int

chgvar &int ( 0 )

dofor &uint from( 1 ) to( 10 )
select
when ( &uint *eq 1 ) +
dmpclpgm
when ( &uint *eq 10 ) +
dmpclpgm
otherwise +
chgvar &int &uint
endselect
enddo
return

endpgm

Rather pointless except that it uses various fancy things that IBM
made available in V5R3... _and_ it compiles back to and runs on V5R2!

How? By compiling it on our *V5R4* system with TGTRLS(V5R2M0). Simple.

While looking for something (which I promptly forgot about), I
noticed that the QSYSV5R2M0 library on one of our V5R3 machines was
different from the library on our V5R4 system. Wondering if the
implication held up, I threw together the above, made sure it
'worked' on V5R4, recompiled back to V5R2, FTPd it via savefile to
one of our V5R2 systems, restored... and Voila! It worked.

Nothing earth-shattering, I know. But when you have a bunch of
systems that you'd like to manage with general control procedures,
this can make a very nice difference.

Am I just now learning something the world has known for years?
(Wouldn't be the first time.) This is 'normal' for V5R2, right?

I've often thought that CL "internal" commands such as DO, SELECT,
DCL, etc., that are only valid in compiled programs should be easier
to create back-level, but I never really expected to see it.

Tom Liotta

--
Tom Liotta
The PowerTech Group, Inc.
19426 68th Avenue South
Kent, WA 98032
Phone 253-872-7788 x313
253-479-1416
Fax 253-872-7904
http://www.powertech.com
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.





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.