date: Tue, 17 Apr 2012 13:04:39 -0400
from: Jon Paris <jon.paris@xxxxxxxxxxxxxx>
subject: Re: RPG still works even the input parameters are not match
On 2012-04-17, at 12:53 PM, rpg400-l-request@xxxxxxxxxxxx wrote:
I'm doing some RPG programs' development and I found that some of theseRPG
require more input parameters from their caller (e.g. a CL program), Ifeel
confuse that they still working even the number of the parameters are not
match, for example, RPG A has 5 input parameter and its caller CL B only
gives it 3.
As long as no attempt is made to _access_ the unpassed parameters then it
will not cause a problem. I would guess that there is some logic in place
that ignores the last two parameters if a specific value occurs in one of
the first three.
Ideally the program should be testing (%Parms) the number of parameters
passed and issuing an error if more than the number passed are required.
However it is not at all uncommon for a sloppy programmer to just ignore
the possibility of such an error and rely instead on the