Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Coding Standards
Message
From
09/07/1998 19:38:09
 
 
To
09/07/1998 18:48:17
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00115272
Message ID:
00115958
Views:
17
>Funny, I always put the operator at the end of the previous line. But I think you're right for arithmetic operators.
>
>Still, I find it more clear if I put the logical operators at the end of line, like in:
>
>
>if (a = b) and ;
>   (a > 0)
>   Some code here
>endif
>
>or a better example:
>
>if ((a = b) and ;
>    (a > 0)) or ;
>   (b < 0)
>   Some code here
>endif
>
>
>IMO, it's easier to verify the parentheses and it makes more clear which are the operators used by each operator.
>
>Another "rule": only one condition by line.
>
>Vlad


Well, standards are all a matter of preference actually. There is a well known VFP author/developer/third party developer whose commenting & coding style I really can't stand. It is soooooooo hard for me to read. I end up reformatting it all.

As for the AND/OR, for me it is easier to pick up the stuff at the beginning of the line.
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform