Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Naming conventions again........
Message
 
To
27/08/1999 14:41:08
Walter Meester
HoogkarspelNetherlands
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00258085
Message ID:
00258635
Views:
15
>George,
>
>>The most important thing is readability. Anything that helps this is useful. Since the bulk of the cost associated with any system is in maintenance and modification, the easier it is to read, the easier it is to maintain and modify. I have heard (not here, but from other programmers), "Well, I can read it." To me this is the height of arrogance.
>
>Well, I know, But the main question i'm asking is: Does naming conventions have a positive effect on readability ?? Of course the large majority here is used to use them, and for that matter it will be hard to get rid of. But I really doubt if you program your code in the right way, (giving good names, comment your code, use indentation, use the OOP style programming) naming convention is of any added value.

As I mentioned to Joe, in the case of a function, I can simply go to the last line and determine the data type being returned by simply looking at the variable. To me, that's added value, since I don't have to try to figure it out by going through the code. I tend to code in very small modules. Out of curiousity, I looked back at my old FPW procedure file and calculated that the average procedure/function was approximately 15 lines, including the comments, the headings, RETURN statements, and the empty line above and below any parameter statement. In fact, I had some, that stripping these things way, were only two lines of code.

>>We don't indulge in these conventions for our own benefit. They are used for the benefit of anyone else who may inherit our work at a later date.
>
>Well this statement seems to come out of someone with a long experience regarding naming convention. But since much has changed over the past few years, I felt that looking at it from another angle might be usefull. Like i said earlier, general accepted principles of today should be questioned tommorow.
>
>I must admit that untill today I still use the type prefix, but i'm willing to drop it, if Readability is improved or if it seems more a overhead than a help.

Walter, there's no way on earth for us to know how the next person is going to react. The best we can do is and always will be subject to our opinion. In my post to Joe, much of what's there was originally implemented because of my schooling. However, when I entered the "real world" I found that, indeed, adhering to these things (even down to the spacing between operators, etc.) does make it easier to read. It's importance was made even clearer to me when I was working in QuickBASIC. Microsoft went to the trouble of including the spacing in the editor (and still do in VB). If they felt it was that important to make it a feature back then, I'd say it's an indication of the value the practice has.
George

Ubi caritas et amor, deus ibi est
Previous
Reply
Map
View

Click here to load this message in the networking platform