[libcxx] r249593 - While researching LWG#2244, I noticed we weren't testing that eofbit was being cleared. Now we are
Marshall Clow via cfe-commits
cfe-commits at lists.llvm.org
Wed Oct 7 12:41:24 PDT 2015
Author: marshall
Date: Wed Oct 7 14:41:24 2015
New Revision: 249593
URL: http://llvm.org/viewvc/llvm-project?rev=249593&view=rev
Log:
While researching LWG#2244, I noticed we weren't testing that eofbit was being cleared. Now we are
Modified:
libcxx/trunk/test/std/input.output/iostream.format/input.streams/istream.unformatted/seekg.pass.cpp
Modified: libcxx/trunk/test/std/input.output/iostream.format/input.streams/istream.unformatted/seekg.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/std/input.output/iostream.format/input.streams/istream.unformatted/seekg.pass.cpp?rev=249593&r1=249592&r2=249593&view=diff
==============================================================================
--- libcxx/trunk/test/std/input.output/iostream.format/input.streams/istream.unformatted/seekg.pass.cpp (original)
+++ libcxx/trunk/test/std/input.output/iostream.format/input.streams/istream.unformatted/seekg.pass.cpp Wed Oct 7 14:41:24 2015
@@ -63,4 +63,13 @@ int main()
is.seekg(-1);
assert(is.fail());
}
+ {
+ testbuf<char> sb(" 123456789");
+ std::istream is(&sb);
+ is.setstate(std::ios_base::eofbit);
+ assert(is.eof());
+ is.seekg(5);
+ assert(is.good());
+ assert(!is.eof());
+ }
}
More information about the cfe-commits
mailing list