On Sun, 2020-08-30 at 20:41 +0200, Julia Lawall wrote:
> On Sun, 30 Aug 2020, Joe Perches wrote:
> > On Sun, 2020-08-30 at 17:46 +0200, Julia Lawall wrote:
> > > Unfortunately this does not work when the declaration
> > is comma terminated and not semicolon terminated.
[]
> I will have to look into it.  It should handle this sort of thing, but it
> is somewhat complex, because the declarations have to be split and this
> specific case may not be handled.

Thanks.  Hope you can get to look at that one day.

> One thing that is possible is to change only the variable name.  If there
> are not many occurrences, one could fix them up afterwards by hand.

And hi again Julia.

I've tried a few variations on finding uses of a function
argument that are not by specific named functions or with
local assignment of that function argument to another
variable without success.

For example:

ssize_t fn(struct device *dev, struct device_attribute *attr, char *buf)
{
*       char *orig = buf;
or
        int count;
...
*       count = local_static_func(some_struct *foo, buf);
}

where local_static_func is not sysfs_emit or sysfs_emit_at

Any clue you can offer?

_______________________________________________
Cocci mailing list
Cocci@systeme.lip6.fr
https://systeme.lip6.fr/mailman/listinfo/cocci

Reply via email to