aboutsummaryrefslogtreecommitdiffstats
path: root/commit.h
diff options
context:
space:
mode:
authorStefan Beller <sbeller@google.com>2018-05-17 15:51:52 -0700
committerJunio C Hamano <gitster@pobox.com>2018-05-18 08:13:10 +0900
commiteee4502baaf8f82c20bcda70625df56ce68dd9b1 (patch)
tree76bdb6640a4a9809a49e9d53c3b8bf26469473d8 /commit.h
parent102de880d24fe66a8916e7c984e5bf8db6be047c (diff)
downloadgit-eee4502baaf8f82c20bcda70625df56ce68dd9b1.tar.gz
shallow: migrate shallow information into the object parser
We need to convert the shallow functions all at the same time as we move the data structures they operate on into the repository. Signed-off-by: Stefan Beller <sbeller@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'commit.h')
-rw-r--r--commit.h9
1 files changed, 3 insertions, 6 deletions
diff --git a/commit.h b/commit.h
index d04bbed81c..45114a95b2 100644
--- a/commit.h
+++ b/commit.h
@@ -190,18 +190,15 @@ extern struct commit_list *get_merge_bases_many_dirty(struct commit *one, int n,
struct oid_array;
struct ref;
-#define register_shallow(r, o) register_shallow_##r(o);
-extern int register_shallow_the_repository(const struct object_id *oid);
+extern int register_shallow(struct repository *r, const struct object_id *oid);
extern int unregister_shallow(const struct object_id *oid);
extern int for_each_commit_graft(each_commit_graft_fn, void *);
-#define is_repository_shallow(r) is_repository_shallow_##r()
-extern int is_repository_shallow_the_repository(void);
+extern int is_repository_shallow(struct repository *r);
extern struct commit_list *get_shallow_commits(struct object_array *heads,
int depth, int shallow_flag, int not_shallow_flag);
extern struct commit_list *get_shallow_commits_by_rev_list(
int ac, const char **av, int shallow_flag, int not_shallow_flag);
-#define set_alternate_shallow_file(r, p, o) set_alternate_shallow_file_##r(p, o)
-extern void set_alternate_shallow_file_the_repository(const char *path, int override);
+extern void set_alternate_shallow_file(struct repository *r, const char *path, int override);
extern int write_shallow_commits(struct strbuf *out, int use_pack_protocol,
const struct oid_array *extra);
extern void setup_alternate_shallow(struct lock_file *shallow_lock,