On Mon, 3 Aug 2020, Denis Efremov wrote: > Is there a difference from cocci point of view between: > > ... when != !is_vmalloc_addr(E) This will only reject cases where the ! is present. Coccinelle doesn't apply isomorphisms to the C source code, so it doesn't detect that eg if (A) B else C could be rewritten as if (!A) C ese B So when != !A would only match when the code is in the second form. > > and > > ... when != is_vmalloc_addr(E) > > Should the latter one be used in most cases? This matches both a call to is_vmalloc_addr and a negated call, so it is more general. julia _______________________________________________ Cocci mailing list Cocci@systeme.lip6.fr https://systeme.lip6.fr/mailman/listinfo/cocci
- Re: [Cocci] [PATCH v4] coccinelle: api: add kvfree scr... Julia Lawall
- Re: [Cocci] [PATCH v4] coccinelle: api: add kvfree scr... Julia Lawall
- Re: [Cocci] [PATCH v4] coccinelle: api: add kvfree... Denis Efremov
- Re: [Cocci] [PATCH v4] coccinelle: api: add kv... Julia Lawall
- [Cocci] [PATCH v5] coccinelle: api: add kvfree script Denis Efremov
- [Cocci] [PATCH v6] coccinelle: api: add kvfree script Denis Efremov
- Re: [Cocci] [PATCH v6] coccinelle: api: add kvfree scr... Julia Lawall
- Re: [Cocci] [PATCH v6] coccinelle: api: add kvfree... Denis Efremov
- Re: [Cocci] [PATCH v6] coccinelle: api: add kv... Julia Lawall
- Re: [Cocci] [PATCH v6] coccinelle: api: add kvfree scr... Denis Efremov
- Re: [Cocci] [PATCH v6] coccinelle: api: add kvfree... Julia Lawall
- [Cocci] [PATCH v7] coccinelle: api: add kfree_mismatch scri... Denis Efremov
- [Cocci] [PATCH v8] coccinelle: api: add kfree_mismatch scri... Denis Efremov
- Re: [Cocci] [PATCH] coccinelle: api: add kvfree script Markus Elfring
- Re: [Cocci] [PATCH] coccinelle: api: add kvfree script Julia Lawall
- Re: [Cocci] coccinelle: api: add kvfree script Markus Elfring
- Re: [Cocci] Coccinelle: Extending capabilities... Markus Elfring
- Re: [Cocci] coccinelle: api: add kvfree script Markus Elfring