[Bug c++/93506] Create hybrid of -I and -isystem that is like -I but deactivates warnings
redi at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Jan 30 10:25:00 GMT 2020
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93506
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2020-01-30
See Also| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=70129
Ever confirmed|0 |1
Severity|normal |enhancement
--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
For example, see PR 70129 where people are having problems because they're
abusing -isystem to get rid of warnings, and that breaks libstdc++ headers.
Rather than yet another -I option (which wouldn't be portable) a better
solution might be a separate option that you use in addition to -I to mark that
path with the "treat as system headers and don't warn"
i.e. -I /some/path -fsystem-headers=/some/path
This assumes that the "it's a system header path" property is a flag that can
be set independently of being in the actual list of system header locations,
rather than just implied.
More information about the Gcc-bugs
mailing list