public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/40465] New: [4.4 Regression] stdio.h related errors including *stream without cstdio at -O
@ 2009-06-16 19:39 tbm at cyrius dot com
2009-06-16 19:39 ` [Bug libstdc++/40465] " tbm at cyrius dot com
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: tbm at cyrius dot com @ 2009-06-16 19:39 UTC (permalink / raw)
To: gcc-bugs
When I compile the following code with gcc 4.4 and -O I get a lot of header
related errors. This doesn't happen without -O or with gcc 4.3.
Is this error expected, and if so, is there any way to improve the output from
gcc to make it clearer what's going on?
--
Summary: [4.4 Regression] stdio.h related errors including
*stream without cstdio at -O
Product: gcc
Version: 4.4.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: tbm at cyrius dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40465
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug libstdc++/40465] [4.4 Regression] stdio.h related errors including *stream without cstdio at -O
2009-06-16 19:39 [Bug libstdc++/40465] New: [4.4 Regression] stdio.h related errors including *stream without cstdio at -O tbm at cyrius dot com
@ 2009-06-16 19:39 ` tbm at cyrius dot com
2009-06-16 19:40 ` tbm at cyrius dot com
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: tbm at cyrius dot com @ 2009-06-16 19:39 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from tbm at cyrius dot com 2009-06-16 19:39 -------
#include <iostream>
namespace zlib_stream {
#include <stdio.h>
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40465
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug libstdc++/40465] [4.4 Regression] stdio.h related errors including *stream without cstdio at -O
2009-06-16 19:39 [Bug libstdc++/40465] New: [4.4 Regression] stdio.h related errors including *stream without cstdio at -O tbm at cyrius dot com
2009-06-16 19:39 ` [Bug libstdc++/40465] " tbm at cyrius dot com
@ 2009-06-16 19:40 ` tbm at cyrius dot com
2009-06-16 19:41 ` pinskia at gcc dot gnu dot org
2009-06-16 19:41 ` tbm at cyrius dot com
3 siblings, 0 replies; 5+ messages in thread
From: tbm at cyrius dot com @ 2009-06-16 19:40 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from tbm at cyrius dot com 2009-06-16 19:40 -------
In file included from /usr/include/stdio.h:903,
from t.cc:4:
/usr/include/bits/stdio.h: In function 'int zlib_stream::vprintf(const char*,
__va_list_tag*)':
/usr/include/bits/stdio.h:39: error: cannot convert 'zlib_stream::_IO_FILE*' to
'FILE*' for argument '1' to 'int zlib_stream::vfprintf(FILE*, const char*,
__va_list_tag*)'
/usr/include/bits/stdio.h: In function 'int
zlib_stream::fgetc_unlocked(FILE*)':
/usr/include/bits/stdio.h:56: error: invalid use of incomplete type 'struct
_IO_FILE'
/usr/include/stdio.h:45: error: forward declaration of 'struct _IO_FILE'
/usr/include/bits/stdio.h:56: error: invalid use of incomplete type 'struct
_IO_FILE'
/usr/include/stdio.h:45: error: forward declaration of 'struct _IO_FILE'
/usr/include/bits/stdio.h:56: error: cannot convert 'FILE*' to
'zlib_stream::_IO_FILE*' for argument '1' to 'int
zlib_stream::__uflow(zlib_stream::_IO_FILE*)'
/usr/include/bits/stdio.h:56: error: invalid use of incomplete type 'struct
_IO_FILE'
/usr/include/stdio.h:45: error: forward declaration of 'struct _IO_FILE'
...
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40465
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug libstdc++/40465] [4.4 Regression] stdio.h related errors including *stream without cstdio at -O
2009-06-16 19:39 [Bug libstdc++/40465] New: [4.4 Regression] stdio.h related errors including *stream without cstdio at -O tbm at cyrius dot com
2009-06-16 19:39 ` [Bug libstdc++/40465] " tbm at cyrius dot com
2009-06-16 19:40 ` tbm at cyrius dot com
@ 2009-06-16 19:41 ` pinskia at gcc dot gnu dot org
2009-06-16 19:41 ` tbm at cyrius dot com
3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2009-06-16 19:41 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from pinskia at gcc dot gnu dot org 2009-06-16 19:41 -------
Putting a standard header inside a namespace is undefined.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40465
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug libstdc++/40465] [4.4 Regression] stdio.h related errors including *stream without cstdio at -O
2009-06-16 19:39 [Bug libstdc++/40465] New: [4.4 Regression] stdio.h related errors including *stream without cstdio at -O tbm at cyrius dot com
` (2 preceding siblings ...)
2009-06-16 19:41 ` pinskia at gcc dot gnu dot org
@ 2009-06-16 19:41 ` tbm at cyrius dot com
3 siblings, 0 replies; 5+ messages in thread
From: tbm at cyrius dot com @ 2009-06-16 19:41 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from tbm at cyrius dot com 2009-06-16 19:41 -------
Forgot to say that adding a
#include <cstdio>
at the beginning helps.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40465
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2009-06-16 19:41 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-16 19:39 [Bug libstdc++/40465] New: [4.4 Regression] stdio.h related errors including *stream without cstdio at -O tbm at cyrius dot com
2009-06-16 19:39 ` [Bug libstdc++/40465] " tbm at cyrius dot com
2009-06-16 19:40 ` tbm at cyrius dot com
2009-06-16 19:41 ` pinskia at gcc dot gnu dot org
2009-06-16 19:41 ` tbm at cyrius dot com
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).