[LLVMbugs] [Bug 9335] New: Overeager setting of eof()

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sat Feb 26 03:35:41 PST 2011


http://llvm.org/bugs/show_bug.cgi?id=9335

           Summary: Overeager setting of eof()
           Product: libc++
           Version: unspecified
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: All Bugs
        AssignedTo: hhinnant at apple.com
        ReportedBy: chris at bubblescope.net
                CC: llvmbugs at cs.uiuc.edu


I believe the following code shows that libc++ is over-eager setting eofbit
when reading chars. Certainly the behavior disagrees with libstdc++, and my
very quick reading of the stream parts of the standard.

#include <sstream>
#include <cassert>

using namespace std;

int main(void)
{
    istringstream ss("1");
    char c;
    ss >> c;
    assert(!ss.eof());
}

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list