threads / patch / 36010

patchPlace cache.h at the first place to match generl rule

Subject: [PATCH] Place cache.h at the first place to match generl rule

## tl;dr

2 messages between Mar 1, 2014 and Mar 1, 2014. Diffs are folded; open one to read it.

replies: 1people: 2as markdown or json

Sun He· Mar 1, 2014, 15:05 UTC · lore
Signed-off-by: Sun He <sunheehnus@gmail.com>
Helped-by: Duy Nguyen <pclouds@gmail.com>
---
 The general rule is if cache.h or git-compat-util.h is included,
 it is the first #include.
 I parsed all the source files, and find many files start with builtin.h.
 And git-compat-util.h is the first in it. So they don't need any change.
 sigchain.c and test-sigchain.c are started with "sigchain.h"
 I checked sigchain.h, and it didn't import any bug.
 But to keep consistant with general rule, we should take this patch.
 Thanks.
 sigchain.c      | 2 +-
 test-sigchain.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
Show changes to 2 files +2 −2

sigchain.c, test-sigchain.c

diff --git a/sigchain.c b/sigchain.c
index 1118b99..faa375d 100644
--- a/sigchain.c
+++ b/sigchain.c
@@ -1,5 +1,5 @@
-#include "sigchain.h"
 #include "cache.h"
+#include "sigchain.h"
 
 #define SIGCHAIN_MAX_SIGNALS 32
 
diff --git a/test-sigchain.c b/test-sigchain.c
index 42db234..e499fce 100644
--- a/test-sigchain.c
+++ b/test-sigchain.c
@@ -1,5 +1,5 @@
-#include "sigchain.h"
 #include "cache.h"
+#include "sigchain.h"
 
 #define X(f) \
 static void f(int sig) { \
-- 
1.9.0.138.g2de3478.dirty
brian m. carlson· Mar 1, 2014, 18:05 UTC · re: Sun He · lore

Re: [PATCH] Place cache.h at the first place to match generl rule

On Sat, Mar 01, 2014 at 11:05:23PM +0800, Sun He wrote:
> Signed-off-by: Sun He <sunheehnus@gmail.com>
> Helped-by: Duy Nguyen <pclouds@gmail.com>
Your commit summary has "generl" instead of "general".
-- 
brian m. carlson / brian with sandals: Houston, Texas, US
+1 832 623 2791 | http://www.crustytoothpaste.net/~bmc | My opinion only
OpenPGP: RSA v4 4096b: 88AC E9B2 9196 305B A994 7552 F1BA 225C 0223 B187

← back to recent threads