This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/11460] Incorrect use of int_type in strstreambuf::pbackfail
- From: "peturr02 at ru dot is" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 8 Jul 2003 09:22:37 -0000
- Subject: [Bug libstdc++/11460] Incorrect use of int_type in strstreambuf::pbackfail
- References: <20030708091510.11460.peturr02@ru.is>
- 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=11460
------- Additional Comments From peturr02 at ru dot is 2003-07-08 09:22 -------
Created an attachment (id=4362)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=4362&action=view)
Test case
This test case shows that, if _M_constant == true and
c == traits_type::to_int_type(gptr()[-1]), strstreambuf::pbackfail(c) fails
when (char)c < 0, but succeeds when (char)c >= 0. It also shows that sungetc
and sputbackc are not affected by the bug.