> func_old(__func__, "%s: hello: %d, %d", myvar, x, y); > > I'm having trouble expressing my smPL to understand the ellipses correctly.
This can be usual. > Here's what I have so far: > > @@ > expression L, F; > @@ > > - func_old(L, F, ...); > + func_old(__func_, ...); > > ... but here, things fall apart: > > init_defs_builtins: /usr/bin/../lib/coccinelle/standard.h > File "contrib/coccinelle/remove_debug.cocci", line 6, column 21, charpos = 68 > around = '...', > whole content = + func_old(__func__, ...); > > Any ideas on what I'm doing wrong? Yes. I hope also that some error messages from the Coccinelle software can become more helpful. > If there's appropriate documentation on this, please feel free to point me > toward it. How do you find the available descriptions in the section “4.1 Basic dots”? http://coccinelle.lip6.fr/docs/main_grammar004.html#sec6 > I feel as though I'm missing something obvious here, so thanks for your time > and for any help you can give. The SmPL ellipsis refers to variable and unknown source code. You tried a simple change specification out which expresses that a specific function call should be adjusted in the same line. But how can anything be readded when the content is unknown? I suggest to increase the precision for the known change aspects like the following. @replacement@ expression L, F; @@ -func_old +current_func ( - L, F + __func__ , ... ) Regards, Markus _______________________________________________ Cocci mailing list [email protected] https://systeme.lip6.fr/mailman/listinfo/cocci
