|
Funny you mention the DO(While) vs DO(Until) thing. You still see, even today, style guides that say "Do not use Do While loops" but what the RPG coders that assimilate this mentality don't seem to realize is, in the language (such as Java or C) for which the "style guide" was written, they do NOT have DOW and DOU operation codes. They have: Do { // insert code to run here; } while ( x != NULL) So what they're talking about is that a programmer can easily miss the fact that the above code is a DO/WHILE loop instead of a do loop. Actually this translates to a DO UNTIL (DOU) in RPG. Bob Cozzi cozzi@rpgiv.com Visit the on-line Midrange Developer forum at: http://www.rpgiv.com > -----Original Message----- > From: rpg400-l-admin@midrange.com [mailto:rpg400-l-admin@midrange.com] On > Behalf Of Smith, Nelson > Sent: Wednesday, February 27, 2002 7:42 AM > To: 'rpg400-l@midrange.com' > Subject: RE: MOVE opcode in freeform (was Strange behavior w/%editc) > > I agree with that, Bob. That has always been one of my pet peeves with > magazine and newsgroup code. The same folks who will argue endlessly over > the merits of DOW vs. DOU, often post such abbreviated hard-to-understand > code, always claiming lack of space or time as the justification for it. > I've even seen some of that from the boys and girls at the lab, and they > should be the evangelists of free-form. Or at least, promoting the proper > use of it. As far as I'm concerned, this list is my number one classroom > and I count on it for "best of breed" examples that I can copy and file away > for future use. > > Where is the best place to find well-written examples of free-form (in any > language)? Are there any good books on style? I'm just now going to V5, and > since I've had so little experience at it, I would like to have some good > examples to go by, initially. Not the most technically correct code, but > code that is easiest to read and maintain. Emphasis on "maintain". I've yet > to decide if it's the way to go or not, but I agree that "mixed" is not a > pretty sight. > > > But to be honest, I have yet to see one example of free-format RPG IV > > code posted to this list that has been written in a way that is similar > > to code written by people that write applications with free-format > > languages for a living (not as a hobby). > > > ************************************************************************ ****** > ************************************************************************ ****** > ************************************************ > This message originates from Lincare Holdings Inc. It contains information > which maybe confidential or privileged and is intended only for the individual > or entity named above. > It is prohibited for anyone else to disclose, copy, distribute or use the > contents of this message. > All personal messages express views solely of the sender, which are not to be > attributed to Lincare Holdings Inc., and may not be copied or distributed > without this disclaimer. > If you received this message in error, please notify us immediately at > MailAdmin@lincare.com or (800) 284-2006. > ************************************************************************ ****** > ************************************************************************ ****** > ************************************************ > > _______________________________________________ > This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list > To post a message email: RPG400-L@midrange.com > To subscribe, unsubscribe, or change list options, > visit: http://lists.midrange.com/cgi-bin/listinfo/rpg400-l > or email: RPG400-L-request@midrange.com > Before posting, please take a moment to review the archives > at http://archive.midrange.com/rpg400-l.
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.