Skip to contentSkip to conversation

cocci: retire is_null_sha1() rule

PATCH New Junio C Hamano 1 participant 1 message Jun 8, 2022

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 cocci: retire is_null_sha1() rule

Since 8d4d86b0 (cache: remove null_sha1, 2019-08-18) removed the is_null_sha1() function, rewrite rules to correct callers of the function to use is_null_oid() instead has become irrelevant, as any new callers of the function will get caught by the compiler much more quickly without spending cycles on Coccinelle.

Remove these rules.

---
 contrib/coccinelle/object_id.cocci | 12 ------------
 1 file changed, 12 deletions(-)
contrib/coccinelle/object_id.cocci +0 -12
index ddf4f22bd7..01f8d6935b 100644
@@ -1,15 +1,3 @@
-@@
-struct object_id OID;
-@@
-- is_null_sha1(OID.hash)
-+ is_null_oid(&OID)
-
-@@
-struct object_id *OIDPTR;
-@@
-- is_null_sha1(OIDPTR->hash)
-+ is_null_oid(OIDPTR)
-
 @@
 struct object_id OID;
 @@
Signature · 1 line
2.36.1-485-g100d6d3ce6