aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/CodingGuidelines
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2022-04-04 10:56:24 -0700
committerJunio C Hamano <gitster@pobox.com>2022-04-04 10:56:24 -0700
commit77ceb113420ce73c35bdea47cb320b08ed1ab0e9 (patch)
tree817e6e6261445cd5fdf6dd2af6cc2c8d93235703 /Documentation/CodingGuidelines
parent909d5b646e9bb49c9c242c82d68e29c451988541 (diff)
parent6563706568b952d85c050b208b5301303d32810c (diff)
downloadgit-77ceb113420ce73c35bdea47cb320b08ed1ab0e9.tar.gz
Merge branch 'jc/coding-guidelines-decl-in-for-loop'
Coding Guidelines clarification. * jc/coding-guidelines-decl-in-for-loop: CodingGuidelines: give deadline for "for (int i = 0; ..."
Diffstat (limited to 'Documentation/CodingGuidelines')
-rw-r--r--Documentation/CodingGuidelines5
1 files changed, 4 insertions, 1 deletions
diff --git a/Documentation/CodingGuidelines b/Documentation/CodingGuidelines
index 1a7bc4591c..b20b2f94f1 100644
--- a/Documentation/CodingGuidelines
+++ b/Documentation/CodingGuidelines
@@ -227,7 +227,10 @@ For C programs:
the first statement (i.e. -Wdeclaration-after-statement).
- Declaring a variable in the for loop "for (int i = 0; i < 10; i++)"
- is still not allowed in this codebase.
+ is still not allowed in this codebase. We are in the process of
+ allowing it by waiting to see that 44ba10d6 (revision: use C99
+ declaration of variable in for() loop, 2021-11-14) does not get
+ complaints. Let's revisit this around November 2022.
- NULL pointers shall be written as NULL, not as 0.