Assume bar application chose to keep it's configuration in it's ownconfig.h.
$ ls -go bar/*/*
-rw-r--r-- 1 0 Jan 28 22:53 bar/part_1/config.h
-rw-r--r-- 1 47 Jan 29 00:54 bar/part_2/bar.c
where
$ cat bar/part_2/bar.c
#include<foo.h>
#include"../part_1/config.h"
and bar/part_1/config.h is intentionally blank.
Nothing wrong with this, completely legit setup. To be more specific, let /path/to/foo/headers := /tmp/R/include, and bar := /tmp/R/bar . Then gcc keeps calm:
I wonder if you volounteer to download simplecpp source code, build it, then run: $ simplecpp -DANY -I /tmp/R/include -I ...
Hi, Daniel. I have attached the archive of /tmp/R/ (in r_testcase.tar.gz) to top-level post.
If you have simplecpp already built, then you can just unpack archive into /tmp/ to be able to run the test case on your side. It might be more simple and straightforward then if I would build simplecpp on my side.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I feel overwhelmed by trouble reports and reviews right now. it's good that problems are reported but when we spend most time reporting more bugs and have no time to fix bugs it's not productive.. :-(
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Suppose foo system library has headers:
and headers are this simple:
Assume bar application chose to keep it's configuration in it's ownconfig.h.
where
and bar/part_1/config.h is intentionally blank.
Nothing wrong with this, completely legit setup. To be more specific, let /path/to/foo/headers := /tmp/R/include, and bar := /tmp/R/bar . Then gcc keeps calm:
However, the equivalent cppcheck invocation fails:
cppcheck reads bar's config.h and includes it into foo.h instead of foo's config.h, I am not kidding.
Do you think this case is purely speculative and has not been from real life? Think foo := perl and bar := openldap, that's where this case came from.
The archive with test case attached. Verified for current release (2.3) and current git (2021-01-28 a9b7f0e27).
thanks. I have the feeling this is a simplecpp issue.
https://github.com/danmar/simplecpp
I wonder if you volounteer to download simplecpp source code, build it, then run:
If you can reproduce some problem then.. then a issue should be created in the simplecpp issue tracker.
Hi, Daniel. I have attached the archive of /tmp/R/ (in r_testcase.tar.gz) to top-level post.
If you have simplecpp already built, then you can just unpack archive into /tmp/ to be able to run the test case on your side. It might be more simple and straightforward then if I would build simplecpp on my side.
I feel overwhelmed by trouble reports and reviews right now. it's good that problems are reported but when we spend most time reporting more bugs and have no time to fix bugs it's not productive.. :-(
If anybody can help out a bit .. please do it..
Understood. I'll try to make a test, but it's not guaranteed :-(