Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
4.1.2, 4.1.3, 4.1.4, 4.2.0
-
None
-
All
-
Compiler Error
Description
The well-formed program below fails to compile with both EDG eccp 3.8 and gcc 4.1.0 (I didn't try others but it's likely a bug in the library)
$ cat t.cpp && make t #include <iterator> int main () { std::istream_iterator<char, char> i; (void)(i == i); }
eccp -c -I/build/sebor/dev/stdlib/include/ansi -D_RWSTDDEBUG -D_RWSTD_USE_CONFIG -I/build/sebor/dev/stdlib/include -I/build/sebor/eccp-3.8-11s/include -I/build/sebor/dev/stdlib/include/ansi -I/build/sebor/PlumHall/lvs06a/conform -I/build/sebor/PlumHall/lvs06a/dst.3 -A -x --template_directory=/build/sebor/eccp-3.8-11s/lib -g --display_error_number --remarks --diag_suppress 193,236,340,401,261,479,487,678,679,815 --diag_suppress 177,381,191,68,550,611,997,549 t.cpp "/build/sebor/dev/stdlib/include/rw/_streamiter.h", line 124: error #349: no operator "!" matches these operands operand types are: ! std::basic_istream<char, std::char_traits<char>> return (__x._C_strm && !!*__x._C_strm) == (__y._C_strm && !!*__y._C_strm); ^ detected during instantiation of "bool std::operator==(const std::istream_iterator<_TypeT, _CharT, _Traits, _Distance> &, const std::istream_iterator<_TypeT, _CharT, _Traits, _Distance> &) [with _TypeT=char, _CharT=char, _Traits=std::char_traits<char>, _Distance=int]" at line 6 of "t.cpp" "/build/sebor/dev/stdlib/include/rw/_streamiter.h", line 124: error #349: no operator "!" matches these operands operand types are: ! std::basic_istream<char, std::char_traits<char>> return (__x._C_strm && !!*__x._C_strm) == (__y._C_strm && !!*__y._C_strm); ^ detected during instantiation of "bool std::operator==(const std::istream_iterator<_TypeT, _CharT, _Traits, _Distance> &, const std::istream_iterator<_TypeT, _CharT, _Traits, _Distance> &) [with _TypeT=char, _CharT=char, _Traits=std::char_traits<char>, _Distance=int]" at line 6 of "t.cpp" 2 errors detected in the compilation of "t.cpp". make: *** [t.o] Error 2
Attachments
Issue Links
- depends upon
-
STDCXX-645 stream iterators into different streams compare equal
- Closed