> In int *i; there is no pointer dereference.

Thanks for this clarification.

The semantic patch language syntax needs a different interpretation
of the desired meaning.
How do you think about to add the mentioned detail to the SmPL manual?


> Y should match a pointer-typed expression.

This view is appropriate.

But I would like to point an other data type distinction out
for the called function.
Thus I imagine that the following SmPL script variant would be incomplete.

@display@
expression* x, y;
@@
*y = (x)(...);
 ... when != y


The metavariable “x” can be restricted to a pointer expression.
But does such specification ensure also that the function pointer is connected
with a pointer return type?

Regards,
Markus
_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci

Reply via email to