DEV: coccinelle: Add rule to use istend() where possible

This replaces `i.ptr + i.len` by `istend()`.
This commit is contained in:
Tim Duesterhus 2021-11-06 15:14:43 +01:00 committed by Willy Tarreau
parent 9c523f1042
commit 958f50454a

View File

@ -41,6 +41,13 @@ struct ist i;
struct ist i;
@@
- (\(i.ptr\|istptr(i)\) + \(i.len\|istlen(i)\))
+ istend(i)
@@
struct ist i;
@@
- i.ptr != NULL
+ isttest(i)