|
In Buck's examples, "RC" was the variable that he "returned". (It had nothing to do with the length of the parameters) When you code a statement like C eval Result = MySubProc('something') the "returned value" is the value that will be assigned to Result. So if MySubProc ended with: c return 50 then (back to the example above) Result would be set to 50. If MySubProc ends with: c return RC Then Result will be assigned whatever value was in the variable "RC" at the time that the return statement was executed. Actually, there was a rather silly bug in Buck's code... he had his return type defined as "10u 0" (an unsigned integer) but he was sometimes returning -1, which is a signed value... :) On Fri, 14 Jul 2000 rbrightman@amclog.com wrote: > > I am not proficient with procedure calls. Could you explain wht RC is 10 long? > It seems that it should be longer to fit the two parms "test" and "Buck" into > it. Also, is the procedure a separate source from the calling program? > +--- | 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-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.