|
Nor is there any run-time mechanism to detect the mis-match.
CONST parms can't be changed by the called subprocedure, unless as Joeexplained
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 theconst
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 realjust a
computers like System i. Sure its simulated but at the end of the day,
pointer is passed by reference, not the value. Sure some things are putinto
registers, but even VALUE parameters are passed by reference under thecovers.
(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.