On Fri, 18 Oct 2013, Joe Perches wrote:

> Any ideas on how to trace call graphs to determine when
> struct pointer arguments can be converted from non const
> to const?

I'm not sure that it is quite possible at the moment.  You would need to 
use iteration, which means you need to pass function names and argument 
positions from one iteration to another.  These arguments are currently 
limited to identifiers.  A function name is an identifier, but an argument 
position is not, ie the n in the metavariable declaration expression 
list[n] es;

I wonder if what you really want to do is work on the types?  It is more 
approximate, but if values of some type are never assigned, then they can 
be const.

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

Reply via email to