THIS IS A TEST INSTANCE ONLY! REPOSITORIES CAN BE DELETED AT ANY TIME!

Git Source Code Mirror - This is a publish-only repository and all pull requests are ignored. Please follow Documentation/SubmittingPatches procedure for any of your improvements.
git
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
782B

  1. #ifndef SHA1_ARRAY_H
  2. #define SHA1_ARRAY_H
  3. struct oid_array {
  4. struct object_id *oid;
  5. int nr;
  6. int alloc;
  7. int sorted;
  8. };
  9. #define OID_ARRAY_INIT { NULL, 0, 0, 0 }
  10. void oid_array_append(struct oid_array *array, const struct object_id *oid);
  11. int oid_array_lookup(struct oid_array *array, const struct object_id *oid);
  12. void oid_array_clear(struct oid_array *array);
  13. typedef int (*for_each_oid_fn)(const struct object_id *oid,
  14. void *data);
  15. int oid_array_for_each(struct oid_array *array,
  16. for_each_oid_fn fn,
  17. void *data);
  18. int oid_array_for_each_unique(struct oid_array *array,
  19. for_each_oid_fn fn,
  20. void *data);
  21. void oid_array_filter(struct oid_array *array,
  22. for_each_oid_fn want,
  23. void *cbdata);
  24. #endif /* SHA1_ARRAY_H */