From -7319875158529698521
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f78e5,73efb588d28d210a,start
X-Google-Attributes: gidf78e5,public
X-Google-ArrivalTime: 2002-10-16 08:22:58 PST
Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!colt.net!kibo.news.demon.net!mutlu.news.demon.net!demon!mail2news.demon.co.uk!devnull
From: NgOrSePbAeM@bigfoot.com ("George van den Driessche")
Newsgroups: comp.std.c++
Subject: basic_istream::get()
Date: Wed, 16 Oct 2002 15:22:58 +0000 (UTC)
Lines: 43
Approved: fjh@cs.mu.oz.au (Fergus Henderson , moderator of comp.std.c++)
Message-ID: <aojvqe$nh5$1$8302bc10@news.demon.co.uk>
X-Trace: mail2news.demon.co.uk 1034781778 12959 10.0.0.1 (16 Oct 2002 15:22:58 GMT)
X-Complaints-To: abuse@demon.net
NNTP-Posting-Date: Wed, 16 Oct 2002 15:22:58 +0000 (UTC)
X-Received: from mulga.cs.mu.oz.au ([128.250.1.22])
	by news.demon.co.uk with esmtp (Exim 4.05)
	id 181q0e-0003Ms-00
	for mail2news@news.news.demon.net; Wed, 16 Oct 2002 15:22:56 +0000
X-Received: from localhost (localhost [[UNIX: localhost]]) by mulga.cs.mu.OZ.AU
	id BAA11273; Thu, 17 Oct 2002 01:22:18 +1000 (EST)
X-Authentication-Warning: mulga.cs.mu.OZ.AU: fjh set sender to devnull@stump.algebra.com using -f
X-Path: comp-std-cpp-robomod!not-for-mail
X-Robomod: STUMP, ichudov@algebra.com (Igor Chudov)
X-Delivered-To: std-c++@ncar.ucar.edu
X-Newsgroups: comp.std.c++
X-Reply-To: "George van den Driessche" <NgOrSePbAeM@bigfoot.com>
X-NNTP-Posting-Date: Wed, 16 Oct 2002 15:15:26 +0000 (UTC)
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
X-Priority: 3
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MSMail-Priority: Normal
X-Spam-Status: No, hits=4.5 required=5.0
	tests=INVALID_MSGID,PRIORITY_NO_NAME,SPAM_PHRASE_00_01
	version=2.41
X-Spam-Level: ****
Xref: archiver1.google.com comp.std.c++:14850

as I understand it, there are six overloads of basic_istream::get(), one of
which returns an int and five of which return a basic_istream&. In
particular, there are:

basic_istream& get(basic_streambuf<E, T> *sb);
basic_istream& get(basic_streambuf<E, T> *sb, E delim);

(these from the Visual C++ 6 documentation, but also I found many
equivalents distributed over the Web.)

However, I find that in the actual implementation, the Visual C++ 6 version
of istream.h declares:

istream& get(streambuf&,char ='\n');

and the STLPort 4.5.0 in stl/_istream.h similarly declares:
_Self& get(basic_streambuf<_CharT, _Traits>& __buf,

char_type __delim);

_Self& get(basic_streambuf<_CharT, _Traits>& __buf)

{ return get(__buf, this->widen('\n')); }

Which is correct, the version that takes a basic_streambuf* or the version
that takes a basic_streambuf&?



Cheers,

George





---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.jamesd.demon.co.uk/csc/faq.html                       ]



