>
> Could you send the exact semantic patch that you tried? Coccinelle should
> allos parsing #defines.
Simply
@@
@@
-#define pr_fmt(fmt) KBUILD_MODNAME
works, but
@@
@@
-#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
fails with
Fatal error: exception Failure("minus: parse error: \n = File
\"patches/1021-pr_fmt_undef.cocci\", line 4, column 38, charpos =
59\n around = '\"', whole content = #define pr_fmt(fmt)
KBUILD_MODNAME \": \" fmt\n")
but even if I want to match just
@@
@@
-#define pr_fmt(fmt) KBUILD_MODNAME fmt
it also fails with
Fatal error: exception Failure("minus: parse error: \n = File
\"patches/1021-pr_fmt_undef.cocci\", line 4, column 0, charpos = 21\n
around = '#define pr_fmt(', whole content = #define pr_fmt(fmt)
KBUILD_MODNAME fmt\n")
Thanks,
/Waldek
_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci