Let's say I have these files:

dir1/dir2/dir3/file1.h
dir1/dir2/dir4/dir5/file2.c

In file2.c, I have this include statement:

#include "../../dir3/file1.h"

This works if I compile the file when I'm in the dir5 directory.

However, if I am in the dir4 directory and do this:

spatch ... ./dir5/file2.c

I will get this error:

Fatal error: exception Sys_error("../../dir3/file1.h": No such file or
directory")

which is technically true, but so what?  Does spatch actually try to
read the contents of file1.h?  If not, why does it care whether the
file exists?  And why doesn't it just ignore the #include line?
_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci

Reply via email to