You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
libcxx/test/std/input.output/iostreams.base/ios/iostate.flags
Eric Fiselier bc06f26c7f Recommit r290750: Fix PR19460 - std::ios is convertible to int.
There were two problems with the initial fix.

1. The added tests flushed out that we misconfigured _LIBCPP_EXPLICIT with GCC.

2. Because the boolean type was a member function template it caused weird link
   errors. I'm assuming due to the vague linkage rules. This time the bool type
   is a non-template member function pointer. That seems to have fixed the
   failing tests. Plus it will end up generating less symbols overall, since
   the bool type is no longer per instantiation.

original commit message below
-----------------------------

std::basic_ios has an operator bool(). In C++11 and later
it is explicit, and only allows contextual implicit conversions.

However explicit isn't available in C++03 which causes std::istream (et al)
to have an implicit conversion to int. This can easily cause ambiguities
when calling operator<< and operator>>.

This patch uses a "bool-like" type in C++03 to work around this. The
"bool-like" type is an arbitrary pointer to member function type. It
will not convert to either int or void*, but will convert to bool.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@290754 91177308-0d34-0410-b5e6-96231b3b80d8
8 years ago
..
bad.pass.cpp Move test into test/std subdirectory. 10 years ago
bool.pass.cpp Recommit r290750: Fix PR19460 - std::ios is convertible to int. 8 years ago
clear.pass.cpp Protect std::ios tests under libcpp-no-exceptions 8 years ago
eof.pass.cpp Move test into test/std subdirectory. 10 years ago
exceptions.pass.cpp Move test into test/std subdirectory. 10 years ago
exceptions_iostate.pass.cpp Protect std::ios tests under libcpp-no-exceptions 8 years ago
fail.pass.cpp Move test into test/std subdirectory. 10 years ago
good.pass.cpp Move test into test/std subdirectory. 10 years ago
not.pass.cpp Move test into test/std subdirectory. 10 years ago
rdstate.pass.cpp Move test into test/std subdirectory. 10 years ago
setstate.pass.cpp Protect std::ios tests under libcpp-no-exceptions 8 years ago