× 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.



Hi David,

For constants I use all uppercase and separate "words" with an underscore (e.g. NORTH_AMERICA).

I tend to prefix global fields with a g, as you did. This includes fields supplied by copybooks. However in best case scenarios, the number of global fields is limited.

I don't prefix variables with their type. Waste of a letter when in WDSCi I can use content assist to see field definition.

While there is a lot of discussion about naming conventions, ultimately it's cosmetic, and the name should be self-documenting.

While on the topic, I'd also like to stress the importance of white-space. As much a style choice as naming is, but for me it hugely impacts readability.

-Kurt

-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of David FOXWELL
Sent: Tuesday, July 06, 2010 8:34 AM
To: RPG programming on the IBM i / System i
Subject: RE: rpg constant


So no one out there uses anything to indicate the scope of the variable/constant?



-----Message d'origine-----
De : rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] De la part de Glenn Hopwood
Envoyé : mardi 6 juillet 2010 13:54
À : RPG programming on the IBM i / System i
Objet : Re: rpg constant

I use almost the same standard as you except I don't treat
constants any different then other program defined fields.

Glenn


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.