1@@
2struct object_id OID;
3@@
4- is_null_sha1(OID.hash)
5+ is_null_oid(&OID)
6
7@@
8struct object_id *OIDPTR;
9@@
10- is_null_sha1(OIDPTR->hash)
11+ is_null_oid(OIDPTR)
12
13@@
14struct object_id OID;
15@@
16- sha1_to_hex(OID.hash)
17+ oid_to_hex(&OID)
18
19@@
20identifier f != oid_to_hex;
21struct object_id *OIDPTR;
22@@
23 f(...) {<...
24- sha1_to_hex(OIDPTR->hash)
25+ oid_to_hex(OIDPTR)
26 ...>}
27
28@@
29expression E;
30struct object_id OID;
31@@
32- sha1_to_hex_r(E, OID.hash)
33+ oid_to_hex_r(E, &OID)
34
35@@
36identifier f != oid_to_hex_r;
37expression E;
38struct object_id *OIDPTR;
39@@
40 f(...) {<...
41- sha1_to_hex_r(E, OIDPTR->hash)
42+ oid_to_hex_r(E, OIDPTR)
43 ...>}
44
45@@
46struct object_id OID;
47@@
48- hashclr(OID.hash)
49+ oidclr(&OID)
50
51@@
52identifier f != oidclr;
53struct object_id *OIDPTR;
54@@
55 f(...) {<...
56- hashclr(OIDPTR->hash)
57+ oidclr(OIDPTR)
58 ...>}
59
60@@
61struct object_id OID1, OID2;
62@@
63- hashcmp(OID1.hash, OID2.hash)
64+ oidcmp(&OID1, &OID2)
65
66@@
67identifier f != oidcmp;
68struct object_id *OIDPTR1, OIDPTR2;
69@@
70 f(...) {<...
71- hashcmp(OIDPTR1->hash, OIDPTR2->hash)
72+ oidcmp(OIDPTR1, OIDPTR2)
73 ...>}
74
75@@
76struct object_id *OIDPTR;
77struct object_id OID;
78@@
79- hashcmp(OIDPTR->hash, OID.hash)
80+ oidcmp(OIDPTR, &OID)
81
82@@
83struct object_id *OIDPTR;
84struct object_id OID;
85@@
86- hashcmp(OID.hash, OIDPTR->hash)
87+ oidcmp(&OID, OIDPTR)
88
89@@
90struct object_id OID1, OID2;
91@@
92- hashcpy(OID1.hash, OID2.hash)
93+ oidcpy(&OID1, &OID2)
94
95@@
96identifier f != oidcpy;
97struct object_id *OIDPTR1;
98struct object_id *OIDPTR2;
99@@
100 f(...) {<...
101- hashcpy(OIDPTR1->hash, OIDPTR2->hash)
102+ oidcpy(OIDPTR1, OIDPTR2)
103 ...>}
104
105@@
106struct object_id *OIDPTR;
107struct object_id OID;
108@@
109- hashcpy(OIDPTR->hash, OID.hash)
110+ oidcpy(OIDPTR, &OID)
111
112@@
113struct object_id *OIDPTR;
114struct object_id OID;
115@@
116- hashcpy(OID.hash, OIDPTR->hash)
117+ oidcpy(&OID, OIDPTR)
118
119@@
120struct object_id *OIDPTR1;
121struct object_id *OIDPTR2;
122@@
123- oidcmp(OIDPTR1, OIDPTR2) == 0
124+ oideq(OIDPTR1, OIDPTR2)
125
126@@
127identifier f != hasheq;
128expression E1, E2;
129@@
130 f(...) {<...
131- hashcmp(E1, E2) == 0
132+ hasheq(E1, E2)
133 ...>}
134
135@@
136struct object_id *OIDPTR1;
137struct object_id *OIDPTR2;
138@@
139- oidcmp(OIDPTR1, OIDPTR2) != 0
140+ !oideq(OIDPTR1, OIDPTR2)
141
142@@
143identifier f != hasheq;
144expression E1, E2;
145@@
146 f(...) {<...
147- hashcmp(E1, E2) != 0
148+ !hasheq(E1, E2)
149 ...>}