]> Pileus Git - ~andy/git/commitdiff
CodingGuidelines: Add a note to avoid assignments inside if()
authorMiklos Vajna <vmiklos@frugalware.org>
Thu, 22 May 2008 23:26:09 +0000 (01:26 +0200)
committerJunio C Hamano <gitster@pobox.com>
Sun, 25 May 2008 05:13:19 +0000 (22:13 -0700)
Signed-off-by: Miklos Vajna <vmiklos@frugalware.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/CodingGuidelines

index 994eb9159a2b0e8a10f4f9510165d420004203bf..d2a0a76e6cfb275080f3b66309591888f5302850 100644 (file)
@@ -89,6 +89,8 @@ For C programs:
    of "else if" statements, it can make sense to add braces to
    single line blocks.
 
+ - We try to avoid assignments inside if().
+
  - Try to make your code understandable.  You may put comments
    in, but comments invariably tend to stale out when the code
    they were describing changes.  Often splitting a function