|
From: "Peter Dow" <pcdow@yahoo.com> Date: Fri, 14 Dec 2001 15:16:27 -0800 >Although I'm still curious -- does VALUE conversion include size as well >as type? If I'm passing 128 bytes (not varying) to a 32K parameter (also >not varying), will it place 32K on the stack (the 128 bytes + blanks)? The parameter gets put on the stack exactly as you coded it in your prototype. Since it's not VARYING, it will be 128 bytes + blanks. Just keep in mind that EVAL rules are used to "assign" a passed parameter to the prototyped parameter. If EVAL would add blanks, then so will parameter passing. > >d Data s 32766a varying > ... >c %addr(Data) + 2: > ... >Note the "+ 2" to skip the embedded length. Will this get me in trouble >in the future? Is it possible IBM will decide to increase the length to >4 bytes? That will continue to work. Even if we someday extended the length, it would be optional, defaulting to 2, and requiring a code change in the RPG source to get the new length. Barbara Morris
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.