|
Œ
Hello Mark,
I read the PADnn fields as being unimportant parts of existing fields but
unimportant "other"
fields will do just as well.
As to the rest: You can't assign a regular field value to a pointer. You can
assign the
address of a field to a pointer (using %ADDR), or you can assign a field value
to the storage
location referenced by the pointer (assuming it has a valid address).
So to re-word your statement:
Assigning the address of a regular field to a pointer will result in
the pointer
referencing (pointing to) that variable's memory area.
Regards,
Simon Coulter.
«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»
«» FlyByNight Software AS/400 Technical Specialists «»
«» Eclipse the competition - run your business on an IBM AS/400. «»
«» «»
«» Phone: +61 3 9419 0175 Mobile: +61 0411 091 400 «»
«» Fax: +61 3 9419 0175 mailto: shc@flybynight.com.au «»
«» «»
«» Windoze should not be open at Warp speed. «»
«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»
//--- forwarded letter -------------------------------------------------------
> X-Mailer: QUALCOMM Windows Eudora Pro Version 4.2.0.58 (demo)
> Date: Sun, 05 Dec 1999 17:04:39 -0500
> From: "M. Lazarus" <mlazarus@ttec.com>
> To: RPG400-L@midrange.com
> Reply-To: RPG400-L@midrange.com
> Subject: Using Pointers
>
> At 10:52 AM 12/4/99 +1100, you wrote:
>
> >Hello Mark,
> >
> >Since Jon hasn't answered this yet, I will. Perhaps you are confused by
> >the fact that there is no explicit pointer definition for Array@. Array@
> >is a based pointer. The compiler
> >automatically defines any pointer used in a BASED definition. (I think
> >that relying on this is sloppy and the programmer should code the pointer
> >anyway, but that's just me!)
>
> You got it - that's what threw me.
>
> >The rest of the code is pretty straight-forward. The only real problem
> >with such a technique
> >is that array elements need to be the same size hence the "PADn" variables.
>
> They are the same size. I thought the "PADn" variables were for
> illustration purposes, i.e. "other" fields.
>
> The way I'm understanding the rest of the code, assigning a regular field
> value to a pointer variable will automatically result in the pointer
> pointing to that variable's memory area. Correct?
>
> -mark
+---
| This is the RPG/400 Mailing List!
| To submit a new message, send your mail to RPG400-L@midrange.com.
| To subscribe to this list send email to RPG400-L-SUB@midrange.com.
| To unsubscribe from this list send email to RPG400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.