|
On Thu, 28 Aug 2003, Bartell, Aaron L. (TC) wrote: > Ah. Yes that example makes much more sense. This is just my opinion, but I > would make separate sub procs with a small variation in the name. > I don't see how that solves the problem? Unless you wanted to write the same code twice, that is. > <<Aaron begins to dream of the day when RPG gets overloading and overriding > sub procs>> > > I will have a party at my place when that day comes;-) I won't. I don't like overloading. I think it's confusing when the compiler gives you an error "procedure not found" and the reason turns out to be that one of your variables is a "short" and the procedure was expecting an "int". That's not intuitive. I don't like it when I search a program for a procedure called "GetCust" fix a bug in it, and it has no effect because there's more than one procedure called GetCust. I don't like having to specify a "mangled" name when creating binder source, or when using %paddr(). The problems of overloading far outweight the minor difficulties of making procedure names like "GetCustByName" instead of "GetCustByNumber"
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.