public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* libstdc++/2976: problem with compiling std::getline
@ 2001-05-27 21:56 snyder
0 siblings, 0 replies; only message in thread
From: snyder @ 2001-05-27 21:56 UTC (permalink / raw)
To: gcc-gnats
>Number: 2976
>Category: libstdc++
>Synopsis: problem with compiling std::getline
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: rejects-legal
>Submitter-Id: net
>Arrival-Date: Sun May 27 21:56:01 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator: scott snyder
>Release: 3.0 20010525 (prerelease)
>Organization:
>Environment:
System: Linux karma 2.2.16-22 #1 Tue Aug 22 16:49:06 EDT 2000 i686 unknown
Architecture: i686
host: i686-pc-linux-gnu
build: i686-pc-linux-gnu
target: i686-pc-linux-gnu
configured with: ../egcs/configure --prefix=/usr/local/egcs --enable-threads=posix --enable-long-long
>Description:
gcc gives errors for the source below.
>How-To-Repeat:
---------------------------------------------------------------------
#include <string>
#include <istream>
void foo (std::istream& s)
{
std::string line;
std::getline (s, line);
}
---------------------------------------------------------------------
>Fix:
This seems to work. (Although it obviates some of the possible
benefit of having istream distinct from iostream in the first place.)
2001-05-27 scott snyder <snyder@fnal.gov>
* include/bits/std_istream.h: Include std_ostream.h.
Index: libstdc++-v3/include/bits/std_istream.h
===================================================================
RCS file: /cvs/gcc/egcs/libstdc++-v3/include/bits/std_istream.h,v
retrieving revision 1.2.2.2
diff -u -p -r1.2.2.2 std_istream.h
--- std_istream.h 2001/05/14 19:49:04 1.2.2.2
+++ std_istream.h 2001/05/28 04:34:41
@@ -38,6 +38,7 @@
#include <bits/std_ios.h>
#include <bits/std_limits.h> // For numeric_limits
+#include <bits/std_ostream.h>
namespace std
{
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2001-05-27 21:56 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-05-27 21:56 libstdc++/2976: problem with compiling std::getline snyder
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).