🌐 AI搜索 & 代理 主页
blob: 03bb04e7071f5f65a3b09f138aa4473fa0a0a655 [file] [log] [blame]
Junio C Hamano5d23e132007-04-10 00:01:271#ifndef PATCH_IDS_H
2#define PATCH_IDS_H
3
Elijah Newrenef3ca952018-08-15 17:54:054#include "diff.h"
5#include "hashmap.h"
6
7struct commit;
8struct object_id;
Nguyễn Thái Ngọc Duya7edadd2018-09-21 15:57:309struct repository;
Elijah Newrenef3ca952018-08-15 17:54:0510
Junio C Hamano5d23e132007-04-10 00:01:2711struct patch_id {
Kevin Willforddfb7a1b2016-07-29 16:19:1712 struct hashmap_entry ent;
Brandon Williams34f3c0e2017-05-30 17:30:5313 struct object_id patch_id;
Kevin Willford683f17e2016-07-29 16:19:1814 struct commit *commit;
Junio C Hamano5d23e132007-04-10 00:01:2715};
16
17struct patch_ids {
Kevin Willforddfb7a1b2016-07-29 16:19:1718 struct hashmap patches;
Junio C Hamano5d23e132007-04-10 00:01:2719 struct diff_options diffopts;
Junio C Hamano5d23e132007-04-10 00:01:2720};
21
Xiaolong Yeded2c092016-04-26 07:51:2122int commit_patch_id(struct commit *commit, struct diff_options *options,
Stephen Boyda8f68552019-04-26 23:51:5723 struct object_id *oid, int, int);
Nguyễn Thái Ngọc Duya7edadd2018-09-21 15:57:3024int init_patch_ids(struct repository *, struct patch_ids *);
Junio C Hamano5d23e132007-04-10 00:01:2725int free_patch_ids(struct patch_ids *);
26struct patch_id *add_commit_patch_id(struct commit *, struct patch_ids *);
27struct patch_id *has_commit_patch_id(struct commit *, struct patch_ids *);
28
29#endif /* PATCH_IDS_H */