You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stdcxx.apache.org by "LANCE DIDUCK, BLOOMBERG/ 731 LEXIN" <LD...@bloomberg.net> on 2005/09/13 17:26:46 UTC

Warnings on Sun CC5.5

Are these warnings OK?

configuring for CC-5.5 on SunOS-5.9-sparc

CC -c -D_RWSTDDEBUG    -D_RWSTD_USE_CONFIG 
-I/home7/ldiduck/couttest/stdcxx-2005-07-19/sun8_11s/include 
-I/home7/ldiduck/couttest/stdcxx-2005-07-19/include  -library=%none -g  +w   
/home7/ldiduck/couttest/stdcxx-2005-07-19/src/collate.cpp 
"/home7/ldiduck/couttest/stdcxx-2005-07-19/src/collate.cpp", line 120: Warning 
(Anachronism): "static" is not allowed and is being ignored.
1 Warning(s) detected.
CC -c -D_RWSTDDEBUG    -D_RWSTD_USE_CONFIG 
-I/home7/ldiduck/couttest/stdcxx-2005-07-19/sun8_11s/include 
-I/home7/ldiduck/couttest/stdcxx-2005-07-19/include  -library=%none -g  +w   
/home7/ldiduck/couttest/stdcxx-2005-07-19/src/strstream.cpp 
"/home7/ldiduck/couttest/stdcxx-2005-07-19/include/strstream", line 188: 
Warning: std::istrstream::rdbuf hides the function 
std::ios::rdbuf(std::streambuf *).
"/home7/ldiduck/couttest/stdcxx-2005-07-19/include/strstream", line 226: 
Warning: std::ostrstream::rdbuf hides the function 
std::ios::rdbuf(std::streambuf *).
"/home7/ldiduck/couttest/stdcxx-2005-07-19/include/strstream", line 266: 
Warning: std::strstream::rdbuf hides the function std::ios::rdbuf(std::streambuf
 *).
3 Warning(s) detected.



Re: Warnings on Sun CC5.5

Posted by Martin Sebor <se...@roguewave.com>.
LANCE DIDUCK, BLOOMBERG/ 731 LEXIN wrote:
> Are these warnings OK?

Yes.

The first one is a compiler bug (we should have a record of it in our
database, which incidentally, I still need to transfer to the ASF Jira,
but I can't find it at the moment; I still see it with 5.7 -- let me
send it to Sun). We should remove the static specifier to silence the
warning.

The second one is a "feature" that Sun disables in their headers with
#pragma disable_warn (since the C++ Standard requires these function
signatures). I don't like the pragma because it turns off all warnings.
I asked for a pragma (or compiler option) to disable individual warnings
long time ago but it still hasn't been implemented.

Martin

> 
> configuring for CC-5.5 on SunOS-5.9-sparc
> 
> CC -c -D_RWSTDDEBUG    -D_RWSTD_USE_CONFIG 
> -I/home7/ldiduck/couttest/stdcxx-2005-07-19/sun8_11s/include 
> -I/home7/ldiduck/couttest/stdcxx-2005-07-19/include  -library=%none -g  +w   
> /home7/ldiduck/couttest/stdcxx-2005-07-19/src/collate.cpp 
> "/home7/ldiduck/couttest/stdcxx-2005-07-19/src/collate.cpp", line 120: Warning 
> (Anachronism): "static" is not allowed and is being ignored.
> 1 Warning(s) detected.
> CC -c -D_RWSTDDEBUG    -D_RWSTD_USE_CONFIG 
> -I/home7/ldiduck/couttest/stdcxx-2005-07-19/sun8_11s/include 
> -I/home7/ldiduck/couttest/stdcxx-2005-07-19/include  -library=%none -g  +w   
> /home7/ldiduck/couttest/stdcxx-2005-07-19/src/strstream.cpp 
> "/home7/ldiduck/couttest/stdcxx-2005-07-19/include/strstream", line 188: 
> Warning: std::istrstream::rdbuf hides the function 
> std::ios::rdbuf(std::streambuf *).
> "/home7/ldiduck/couttest/stdcxx-2005-07-19/include/strstream", line 226: 
> Warning: std::ostrstream::rdbuf hides the function 
> std::ios::rdbuf(std::streambuf *).
> "/home7/ldiduck/couttest/stdcxx-2005-07-19/include/strstream", line 266: 
> Warning: std::strstream::rdbuf hides the function std::ios::rdbuf(std::streambuf
>  *).
> 3 Warning(s) detected.
>