From 5a8643eff1e59f1cf96da9875d5716e88f480710 Mon Sep 17 00:00:00 2001 From: "brian m. carlson" Date: Tue, 19 Feb 2019 00:04:53 +0000 Subject: khash: move oid hash table definition Move the oid khash table definition to khash.h and define a typedef for it, similar to the one we have for unsigned char pointers. Define variants that are maps as well. Signed-off-by: brian m. carlson Signed-off-by: Junio C Hamano --- oidset.h | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'oidset.h') diff --git a/oidset.h b/oidset.h index c9d0f6d3cc..14f18f791f 100644 --- a/oidset.h +++ b/oidset.h @@ -16,18 +16,6 @@ * table overhead. */ -static inline unsigned int oid_hash(struct object_id oid) -{ - return sha1hash(oid.hash); -} - -static inline int oid_equal(struct object_id a, struct object_id b) -{ - return oideq(&a, &b); -} - -KHASH_INIT(oid, struct object_id, int, 0, oid_hash, oid_equal) - /** * A single oidset; should be zero-initialized (or use OIDSET_INIT). */ -- cgit v1.2.3