CodingGuidelines: mention "static" and "extern"
commit89a9f2c862db52d99e4dd78e799f4b36dac597ac
authorJeff King <peff@peff.net>
Thu, 8 Feb 2018 21:38:06 +0000 (8 16:38 -0500)
committerJunio C Hamano <gitster@pobox.com>
Thu, 8 Feb 2018 22:20:43 +0000 (8 14:20 -0800)
treeede885d3eaea0bbd1e88e10795c54789f5761de1
parent5be1f00a9a701532232f57958efab4be8c959a29
CodingGuidelines: mention "static" and "extern"

It perhaps goes without saying that file-local stuff should
be marked static, but it does not hurt to remind people.

Less obvious is that we are settling on "do not include
extern in function declarations". It is already the default
unless the function was previously declared static (but if
you are following a static declaration with an unmarked one,
you should think about why you are declaring the thing
twice). And so it just becomes an extra noise-word in our
header files.

We used to give the opposite advice, so there are quite a
few "extern" markers in early Git code. But this at least
makes a concrete suggestion that we can follow going
forward.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/CodingGuidelines