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



Mark,

I know the basic stuff won't work. For instance, this won't compile:

P myproc S
D PI
D parm1 10A Const
D temp1 S 10A Based(temp1ptr)

/free
temp1ptr = %addr( parm1 );
temp1 = 'NEWVALUE';
/end-free

The only sure-fire method I know of is using the NPM_PARMLIST_ADDR MI
builtin (
http://publib.boulder.ibm.com/iseries/v5r1/ic2924/tstudio/tech_ref/mi/NPMPARM.htm).
See this thread for details:
http://forums.systeminetwork.com/isnetforums/showthread.php?t=45802 - post
#14 contains my code for doing this. Once you have the array of argument
pointers, you can play with them to your hearts content.

Rory
On Wed, Jan 28, 2009 at 12:56 PM, M. Lazarus <mlazarus@xxxxxxxx> wrote:

Doug,

I recall playing a bit and trying to fool the compiler on a CONST
variable using a DS. Has someone tried this recently? I'd like to
see a working sample that the compiler won't catch. I think that
Scott had posted something, but it was a lot more involved than just
overlaying with a DS.

VALUE is only really valid when calling a procedure, not a program,
so it might be more difficult to retrofit older systems.

-mark


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.