|
CONST parms can't be changed by the called subprocedure, unless as Joe
explained
there is some subversion going on. But even then, if I recall correctly, there
is in fact a runtime error that will occur if you pull the address-of the const
and try to modify it. OS/400 pointers are very secure.
The stack thing is all academic--it doesn't really occur that way on real
computers like System i. Sure its simulated but at the end of the day, just a
pointer is passed by reference, not the value. Sure some things are put into
registers, but even VALUE parameters are passed by reference under the covers.
(Correctly if I'm wrong about this; if I am, I'm sure someone will.)
As an Amazon Associate we earn from qualifying purchases.
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.