[ http://issues.apache.org/jira/browse/STDCXX-155?page=all ]

Martin Sebor updated STDCXX-155:
--------------------------------

    Fix Version: 4.2
                     (was: 4.1.4)

> [Sun C++ 5.7] overloading ambiguity on std::operator<<(ostream&, const 
> string&)
> -------------------------------------------------------------------------------
>
>          Key: STDCXX-155
>          URL: http://issues.apache.org/jira/browse/STDCXX-155
>      Project: C++ Standard Library
>         Type: Bug

>   Components: 27. Input/Output
>     Versions: 4.1.3
>  Environment: CC: Sun C++ 5.7 Patch 117830-04 2005/09/14
>     Reporter: Martin Sebor
>     Assignee: Martin Sebor
>     Priority: Critical
>      Fix For: 4.2

>
> The examples below fail to compile with Sun C++ 5.7 on Solaris 9. The output 
> of CC -V is:
> CC: Sun C++ 5.7 Patch 117830-04 2005/09/14
> make: Entering directory `/build/sebor/sunpro-5.7-8d/examples'
> CC -c -D_RWSTD_USE_CONFIG -I/build/sebor/sunpro-5.7-8d/include 
> -I/build/sebor/dev/stdlib/include -I/build/sebor/dev/stdlib/examples/include  
> -library=%none -O  +w  /build/sebor/dev/stdlib/examples/tutorial/alg1.cpp
> "/build/sebor/dev/stdlib/include/sstream", line 353: Warning: 
> std::ostringstream::rdbuf hides the function std::ios::rdbuf(std::streambuf 
> *).
> "/build/sebor/dev/stdlib/examples/tutorial/alg1.cpp", line 148:     Where: 
> While specializing "std::ostringstream ".
> "/build/sebor/dev/stdlib/examples/tutorial/alg1.cpp", line 148:     Where: 
> Specialized in non-template code.
> "/build/sebor/dev/stdlib/include/rw/_streamiter.h", line 148: Error: 
> Overloading ambiguity between "std::operator<<<char, char, 
> std::char_traits<char>, std::char_traits<char>, 
> std::allocator<char>>(std::ostream &, const std::string &)" and 
> "std::operator<<<char, std::char_traits<char>, 
> std::allocator<char>>(std::ostream &, const std::string &)".
> "/build/sebor/dev/stdlib/include/rw/_algobase.h", line 88:     Where: While 
> instantiating "std::ostream_iterator<std::string, char, 
> std::char_traits<char>>::operator=(const std::string &)".
> "/build/sebor/dev/stdlib/include/rw/_algobase.h", line 88:     Where: 
> Instantiated from non-template code.
> 1 Error(s) and 1 Warning(s) detected.
> make: *** [alg1.o] Error 1
> CC -c -D_RWSTD_USE_CONFIG -I/build/sebor/sunpro-5.7-8d/include 
> -I/build/sebor/dev/stdlib/include -I/build/sebor/dev/stdlib/examples/include  
> -library=%none -O  +w  /build/sebor/dev/stdlib/examples/manual/bitset.cpp
> "/build/sebor/dev/stdlib/include/bitset", line 684: Error: Overloading 
> ambiguity between "std::operator<<<char, char, std::char_traits<char>, 
> std::char_traits<char>, std::allocator<char>>(std::ostream &, const 
> std::string &)" and "std::operator<<<char, std::char_traits<char>, 
> std::allocator<char>>(std::ostream &, const std::string &)".
> 1 Error(s) detected.
> make: *** [bitset.o] Error 1
> CC -c -D_RWSTD_USE_CONFIG -I/build/sebor/sunpro-5.7-8d/include 
> -I/build/sebor/dev/stdlib/include -I/build/sebor/dev/stdlib/examples/include  
> -library=%none -O  +w  /build/sebor/dev/stdlib/examples/manual/complex.cpp
> "/build/sebor/dev/stdlib/include/sstream", line 353: Warning: 
> std::ostringstream::rdbuf hides the function std::ios::rdbuf(std::streambuf 
> *).
> "/build/sebor/dev/stdlib/include/complex", line 930:     Where: While 
> specializing "std::ostringstream ".
> "/build/sebor/dev/stdlib/include/complex", line 930:     Where: Specialized 
> in non-template code.
> "/build/sebor/dev/stdlib/include/complex", line 935: Error: Overloading 
> ambiguity between "std::operator<<<char, char, std::char_traits<char>, 
> std::char_traits<char>, std::allocator<char>>(std::ostream &, const 
> std::string &)" and "std::operator<<<char, std::char_traits<char>, 
> std::allocator<char>>(std::ostream &, const std::string &)".
> 1 Error(s) and 1 Warning(s) detected.
> make: *** [complex.o] Error 1
> CC -c -D_RWSTD_USE_CONFIG -I/build/sebor/sunpro-5.7-8d/include 
> -I/build/sebor/dev/stdlib/include -I/build/sebor/dev/stdlib/examples/include  
> -library=%none -O  +w  /build/sebor/dev/stdlib/examples/tutorial/complx.cpp
> "/build/sebor/dev/stdlib/include/sstream", line 353: Warning: 
> std::ostringstream::rdbuf hides the function std::ios::rdbuf(std::streambuf 
> *).
> "/build/sebor/dev/stdlib/include/complex", line 930:     Where: While 
> specializing "std::ostringstream ".
> "/build/sebor/dev/stdlib/include/complex", line 930:     Where: Specialized 
> in non-template code.
> "/build/sebor/dev/stdlib/include/complex", line 935: Error: Overloading 
> ambiguity between "std::operator<<<char, char, std::char_traits<char>, 
> std::char_traits<char>, std::allocator<char>>(std::ostream &, const 
> std::string &)" and "std::operator<<<char, std::char_traits<char>, 
> std::allocator<char>>(std::ostream &, const std::string &)".
> 1 Error(s) and 1 Warning(s) detected.
> make: *** [complx.o] Error 1
> CC -c -D_RWSTD_USE_CONFIG -I/build/sebor/sunpro-5.7-8d/include 
> -I/build/sebor/dev/stdlib/include -I/build/sebor/dev/stdlib/examples/include  
> -library=%none -O  +w  /build/sebor/dev/stdlib/examples/manual/locale.cpp
> "/build/sebor/dev/stdlib/include/rw/_streamiter.h", line 148: Error: 
> Overloading ambiguity between "std::operator<<<char, char, 
> std::char_traits<char>, std::char_traits<char>, 
> std::allocator<char>>(std::ostream &, const std::string &)" and 
> "std::operator<<<char, std::char_traits<char>, 
> std::allocator<char>>(std::ostream &, const std::string &)".
> "/build/sebor/dev/stdlib/include/rw/_algobase.h", line 88:     Where: While 
> instantiating "std::ostream_iterator<std::string, char, 
> std::char_traits<char>>::operator=(const std::string &)".
> "/build/sebor/dev/stdlib/include/rw/_algobase.h", line 88:     Where: 
> Instantiated from non-template code.
> 1 Error(s) detected.
> make: *** [locale.o] Error 1
> CC -c -D_RWSTD_USE_CONFIG -I/build/sebor/sunpro-5.7-8d/include 
> -I/build/sebor/dev/stdlib/include -I/build/sebor/dev/stdlib/examples/include  
> -library=%none -O  +w  /build/sebor/dev/stdlib/examples/tutorial/spell.cpp
> "/build/sebor/dev/stdlib/include/fstream", line 444: Warning: 
> std::ifstream::rdbuf hides the function std::ios::rdbuf(std::streambuf *).
> "/build/sebor/dev/stdlib/examples/tutorial/spell.cpp", line 67:     Where: 
> While specializing "std::ifstream ".
> "/build/sebor/dev/stdlib/examples/tutorial/spell.cpp", line 67:     Where: 
> Specialized in non-template code.
> "/build/sebor/dev/stdlib/include/rw/_streamiter.h", line 148: Error: 
> Overloading ambiguity between "std::operator<<<char, char, 
> std::char_traits<char>, std::char_traits<char>, 
> std::allocator<char>>(std::ostream &, const std::string &)" and 
> "std::operator<<<char, std::char_traits<char>, 
> std::allocator<char>>(std::ostream &, const std::string &)".
> "/build/sebor/dev/stdlib/include/rw/_algobase.h", line 88:     Where: While 
> instantiating "std::ostream_iterator<std::string, char, 
> std::char_traits<char>>::operator=(const std::string &)".
> "/build/sebor/dev/stdlib/include/rw/_algobase.h", line 88:     Where: 
> Instantiated from non-template code.
> 1 Error(s) and 1 Warning(s) detected.
> make: *** [spell.o] Error 1
> make: Target `all' not remade because of errors.
> make: Leaving directory `/build/sebor/sunpro-5.7-8d/examples'

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply via email to