|
>> I am aware that this is the accepted practice, but I think it is a waste of time. As I understand it, data structs are not initialized at module start, so a plain old qualified data struct will not impact the running of a program in that way. Data structures are initialized to spaces by default. The INZ keyword on a DS causes each field to be initialized according to its type (i.e. zero for numerics) >> And in terms of the system having to allocate space for the data struct, I don't think there is any difference in module startup when the static storage of a module is size X vs size X+ %size(template_data_struct). In all probability there is no measurable difference in the quoted case. However that is not a realistic picture. In reality you might have 20, 30 or more structures defined that are simply typedefs. Using the based approach will avoid potential storage problems no matter how many instances of the item you subsequently create. Also it is not simply a question of module startup - since you are affecting the size of the program's storage you are affecting the amount that needs to be paged. I would also use the technique to help standardize my typedefs so that I can use /Copy to bring them all in without using storage etc. Jon Paris Partner400 www.Partner400.com www.RPGWorld.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.