4 int oidset_contains(const struct oidset *set, const struct object_id *oid)
6 khiter_t pos = kh_get_oid(&set->set, *oid);
7 return pos != kh_end(&set->set);
10 int oidset_insert(struct oidset *set, const struct object_id *oid)
13 kh_put_oid(&set->set, *oid, &added);
17 int oidset_remove(struct oidset *set, const struct object_id *oid)
19 khiter_t pos = kh_get_oid(&set->set, *oid);
20 if (pos == kh_end(&set->set))
22 kh_del_oid(&set->set, pos);
26 void oidset_clear(struct oidset *set)
28 kh_release_oid(&set->set);