|
Joep Beckeringh wrote: > > Personally I never use 'like' in a prototype. The prototype is the interface > to > 'the outside world' and should be clear and unambiguous about the data types > the > program or procedure expects. > I think LIKE is good in a prototype, but only if the thing being defined-like is also in the same /copy file. * For copy file XYZ D XYZ_TYPES DS QUALIFIED BASED(@) D name 10a D idno 5i 0 D XYZ_myfile_types... D E DS QUALIFIED BASED(@) D XYZ_something DS QUALIFIED BASED(@) D fld1 100a D arr 1n dim(3) D someproc PR LIKE(XYZ_TYPES.name) D parm1 LIKE(XYZ_TYPES.idno) D parm2 LIKEDS(XYZ_something) D parm3 LIKE(XYZ_myfile_types.fld1) Then the user can also use LIKE and LIKEDS to define variables that will work with the prototypes. By the way, whenever dates or times are defined in a /COPY file, DATFMT or TIMFMT should always be used.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.