× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



From: Steve Richter

a GC makes two basic building blocks of code cost free. procedure
return values and adding items to a collection.

When you have a GC you can write code like so:
CustomerRecord[] customers = GetListOfCustomers( arg1: arg2 ) ;

without it:
CustomerRecord[] customers ;
GetListOfCustomers( customers: arg1: arg2 ) ;
// dont forget to free the customers struct!

the GC version is more readable.

See, this is the reason why I won't argue technical syntax. You say it's
more readable, and indeed it may be to some people. But that's not a valid
reason to fundamentally change the language.

Your entire argument has to do with "readability" which is pretty much a
non-starter for me. Again, please let me know what problem can't be solved
in RPG today.

By the way, I agree that the variably-sized collection concept is an issue.
But it's a much bigger issue than garbage collection, because GC doesn't
address the issue of paging collections. And in my opinion, letting the
operating system handle collections without the programmer actually doing
anything is what leads to coders reading entire transaction files into
memory. But that's a different argument for a different day.

Okay, done here. I just wanted to know what your point was, and in this
case it's pretty standard: you want to make RPG look like an OO language.
Me, I say allocate as necessary and end the activation group when you're
done.

Joe


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.