On Mon, 22 Feb 2010, Nicholas Mc Guire wrote:

> On Mon, 22 Feb 2010, SF Markus Elfring wrote:
> 
> > > Sorry, I'm not sure what the last bit is referring to.
> > > Extend in what way?
> > 
> > It would be nice if the same include parameters can be applied that I am 
> > used to
> > with usual C compilers.
> >
> can't that be simply resolved by running spatch against the preprocessor 
> output rather than the C file ? Extending this would hardly ever cover every 
> possible behavior of existing compilers but I guess they all can dump 
> preprocessor output.

It depends what your goal is. If you are just looking for bugs then it 
might be ok, although I don't know whether spatch interprets the #line 
directives.  If you want to do transformation, then you will be 
transforming the expanded code, which will give a result that is not very 
readable/maintainable.  Also, if you want to anything that depends on the 
name of a macro, then running the preprocessor will cause that to 
diappear.

Allowing more than one -I path is probably doable.  It will be up to the 
user to figure out what those include paths should be, though.

julia
_______________________________________________
Cocci mailing list
[email protected]
http://lists.diku.dk/mailman/listinfo/cocci
(Web access from inside DIKUs LAN only)

Reply via email to