public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug c++/94843] New: if i use pch and specify '-include' twice compilation fails @ 2020-04-29 6:54 m+gccbugs at gshep dot ru 2020-04-29 6:58 ` [Bug c++/94843] " m+gccbugs at gshep dot ru 2020-04-29 7:20 ` [Bug pch/94843] " rguenth at gcc dot gnu.org 0 siblings, 2 replies; 3+ messages in thread From: m+gccbugs at gshep dot ru @ 2020-04-29 6:54 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94843 Bug ID: 94843 Summary: if i use pch and specify '-include' twice compilation fails Product: gcc Version: 9.3.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: m+gccbugs at gshep dot ru Target Milestone: --- Hi! The following commands give "cc1plus fatal error ./empty.h No such file or directory ; compilation terminated." ========================================= mkdir 111 touch 111/empty.h echo 'int main(){ return 0; }' > a.cpp find g++ -g -Winvalid-pch -x c++-header -o empty.h.gch -c 111/empty.h g++ -I. -I111 -g -Winvalid-pch -include empty.h -include empty.h -o a.o -c a.cpp ========================================= We encountered this issue on our project except that we have 'include "empty.h"' in cpp source file and one '-include' command line parameter. Is this a bug or am I missing anything? Thanks in advance. ^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug c++/94843] if i use pch and specify '-include' twice compilation fails 2020-04-29 6:54 [Bug c++/94843] New: if i use pch and specify '-include' twice compilation fails m+gccbugs at gshep dot ru @ 2020-04-29 6:58 ` m+gccbugs at gshep dot ru 2020-04-29 7:20 ` [Bug pch/94843] " rguenth at gcc dot gnu.org 1 sibling, 0 replies; 3+ messages in thread From: m+gccbugs at gshep dot ru @ 2020-04-29 6:58 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94843 --- Comment #1 from gccshep <m+gccbugs at gshep dot ru> --- environment: $ uname -a Linux 5user6-7VirtualBox890 5.3.0-46-generic #38~18.04.1-Ubuntu SMP Tue Mar 31 04:17:56 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux tested with g++-8/9 : $ g++-8 --version g++-8 (Ubuntu 8.4.0-1ubuntu1~18.04) 8.4.0 Copyright (C) 2018 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. $ g++-9 --version g++-9 (Ubuntu 9.3.0-11ubuntu0~18.04.1) 9.3.0 Copyright (C) 2019 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. It seems like it is reproducible with gcc too. Also reproduced this with gcc/++ 5.5.0 on Slackware 64. ^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug pch/94843] if i use pch and specify '-include' twice compilation fails 2020-04-29 6:54 [Bug c++/94843] New: if i use pch and specify '-include' twice compilation fails m+gccbugs at gshep dot ru 2020-04-29 6:58 ` [Bug c++/94843] " m+gccbugs at gshep dot ru @ 2020-04-29 7:20 ` rguenth at gcc dot gnu.org 1 sibling, 0 replies; 3+ messages in thread From: rguenth at gcc dot gnu.org @ 2020-04-29 7:20 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94843 Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Component|c++ |pch Keywords| |diagnostic --- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> --- The constraints for the use of PCH are quite strict and a second include of the same PCH is definitely not supported. The failure mode isn't very helpful though. ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-04-29 7:20 UTC | newest] Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2020-04-29 6:54 [Bug c++/94843] New: if i use pch and specify '-include' twice compilation fails m+gccbugs at gshep dot ru 2020-04-29 6:58 ` [Bug c++/94843] " m+gccbugs at gshep dot ru 2020-04-29 7:20 ` [Bug pch/94843] " rguenth at gcc dot gnu.org
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).