diff mbox series

[21/23] object-store.h: reduce unnecessary includes

Message ID 1aa36d91b596522ba01d24b50149bb507e697958.1681614207.git.gitgitgadget@gmail.com (mailing list archive)
State Accepted
Commit e3d2f20e6f14d3cba641a365a733a615278e9e5e
Headers show
Series Header cleanups (more splitting of cache.h and simplifying a few other deps) | expand

Commit Message

Elijah Newren April 16, 2023, 3:03 a.m. UTC
From: Elijah Newren <newren@gmail.com>

Signed-off-by: Elijah Newren <newren@gmail.com>
---
 object-file.c      | 1 +
 object-name.c      | 1 +
 object-store.h     | 8 ++++----
 submodule-config.c | 1 +
 4 files changed, 7 insertions(+), 4 deletions(-)
diff mbox series

Patch

diff --git a/object-file.c b/object-file.c
index 8e0df7360ae..921a717d8a5 100644
--- a/object-file.c
+++ b/object-file.c
@@ -38,6 +38,7 @@ 
 #include "packfile.h"
 #include "object-file.h"
 #include "object-store.h"
+#include "oidtree.h"
 #include "promisor-remote.h"
 #include "setup.h"
 #include "submodule.h"
diff --git a/object-name.c b/object-name.c
index 5ccbe854b60..88d839f70bc 100644
--- a/object-name.c
+++ b/object-name.c
@@ -14,6 +14,7 @@ 
 #include "remote.h"
 #include "dir.h"
 #include "oid-array.h"
+#include "oidtree.h"
 #include "packfile.h"
 #include "pretty.h"
 #include "object-store.h"
diff --git a/object-store.h b/object-store.h
index f9d225783ae..23ea86d3702 100644
--- a/object-store.h
+++ b/object-store.h
@@ -2,16 +2,16 @@ 
 #define OBJECT_STORE_H
 
 #include "object.h"
-#include "oidmap.h"
 #include "list.h"
-#include "oid-array.h"
-#include "strbuf.h"
 #include "thread-utils.h"
 #include "khash.h"
 #include "dir.h"
-#include "oidtree.h"
 #include "oidset.h"
 
+struct oidmap;
+struct oidtree;
+struct strbuf;
+
 struct object_directory {
 	struct object_directory *next;
 
diff --git a/submodule-config.c b/submodule-config.c
index 7fc0812b644..58dfbde9ae5 100644
--- a/submodule-config.c
+++ b/submodule-config.c
@@ -12,6 +12,7 @@ 
 #include "object-name.h"
 #include "object-store.h"
 #include "parse-options.h"
+#include "thread-utils.h"
 #include "tree-walk.h"
 
 /*