public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug pch/14130] New: #pragma once ignored with Precompiled header
@ 2004-02-12 15:44 tfautre at pandora dot be
  2004-02-12 15:50 ` [Bug pch/14130] " tfautre at pandora dot be
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: tfautre at pandora dot be @ 2004-02-12 15:44 UTC (permalink / raw)
  To: gcc-bugs

When not using PCH, GCC 3.4 seems to have fixed all the problems with #pragma once.
But with PCH, #pragma once seems broken again. The behavior would be best
described as if #pragma once is ignored and the header is included multiple times.

Note: #pragma once is used in headers included by the precompiled header. The
precompiled header itself uses a #ifndef-#define-#endif header guardian mechanism.

I've tested this on three different version of GCC (3.4 20040128, 3.4 20040211
and 3.5 20040113). All versions failed the test.

I'll try to attach the whole project to this bug report.
It contains:
 - a test project with 3 files: PchTest.cpp (main file), foobar.h (foobar class)
and stdafx.h (the precompiled header wanna be)
 - two makefiles, one without PCH, one with (don't forget to call "make clean"
when switching makefile)
 - full reports for the various GCC versions

-- 
           Summary: #pragma once ignored with Precompiled header
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: pch
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: tfautre at pandora dot be
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14130


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2004-02-12 16:50 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-02-12 15:44 [Bug pch/14130] New: #pragma once ignored with Precompiled header tfautre at pandora dot be
2004-02-12 15:50 ` [Bug pch/14130] " tfautre at pandora dot be
2004-02-12 15:51 ` tfautre at pandora dot be
2004-02-12 15:51 ` tfautre at pandora dot be
2004-02-12 15:52 ` tfautre at pandora dot be
2004-02-12 15:52 ` tfautre at pandora dot be
2004-02-12 15:53 ` tfautre at pandora dot be
2004-02-12 15:55 ` tfautre at pandora dot be
2004-02-12 16:50 ` pinskia at gcc dot gnu dot 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).