interplane.Get Omega
Read in your language

git

[Ported from github.com/git/git] Sync with Git 2.56.1

Brought by drakestapleton

branch master Branches Tags History

git / tools / coccinelle / hash.cocci

63 lines · 1067 bytes Raw Blame History
1@@
2identifier f != git_hash_init;
3expression ALGO;
4struct git_hash_ctx *CTX;
5@@
6 f(...) {<...
7- ALGO->init_fn(CTX);
8+ git_hash_init(CTX, ALGO);
9 ...>}
10
11@@
12identifier f != git_hash_clone;
13expression ALGO;
14struct git_hash_ctx *SRC;
15struct git_hash_ctx *DST;
16@@
17 f(...) {<...
18- ALGO->clone_fn(DST, SRC);
19+ git_hash_clone(DST, SRC);
20 ...>}
21
22@@
23identifier f != git_hash_update;
24expression ALGO;
25struct git_hash_ctx *CTX;
26expression list ARGS;
27@@
28 f(...) {<...
29- ALGO->update_fn(CTX, ARGS);
30+ git_hash_update(CTX, ARGS);
31 ...>}
32
33@@
34identifier f != git_hash_final;
35expression ALGO;
36struct git_hash_ctx *CTX;
37expression list ARGS;
38@@
39 f(...) {<...
40- ALGO->final_fn(ARGS, CTX);
41+ git_hash_final(ARGS, CTX);
42 ...>}
43
44@@
45identifier f != git_hash_final_oid;
46expression ALGO;
47struct git_hash_ctx *CTX;
48expression list ARGS;
49@@
50 f(...) {<...
51- ALGO->final_oid_fn(ARGS, CTX);
52+ git_hash_final_oid(ARGS, CTX);
53 ...>}
54
55@@
56identifier f != git_hash_discard;
57expression ALGO;
58struct git_hash_ctx *CTX;
59@@
60 f(...) {<...
61- ALGO->discard_fn(CTX);
62+ git_hash_discard(CTX);
63 ...>}