This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/10975] incorrect initial ostringstream::tellp()
- From: "from-bugzilla at geek-central dot gen dot nz" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Jul 2003 08:58:42 -0000
- Subject: [Bug libstdc++/10975] incorrect initial ostringstream::tellp()
- References: <20030526002442.10975.from-bugzilla@geek-central.gen.nz>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10975
------- Additional Comments From from-bugzilla at geek-central dot gen dot nz 2003-07-18 08:58 -------
brendan@zen.org wrote:
>As such, since there's no space yet for seekoff() to move inside the
>basic_stringbuf, it gives back the -1 value which tellp() relays to the call
>in the testcase.
That's an implementation issue. I don't see why such implementation
issues should cause a difference in the semantics. Consider: the
ostream object is fully initialized and ready for use. Nothing has been
written to it yet. Therefore the output position should be 0. This is true if
output is going to a file, why shouldn't it be true for output going to a
string?