This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/13932] [3.3/3.4/3.5 regression] duplicate warning message for conversion
- From: "gdr at integrable-solutions dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 30 Jan 2004 16:03:54 -0000
- Subject: [Bug c++/13932] [3.3/3.4/3.5 regression] duplicate warning message for conversion
- References: <20040130144911.13932.bangerth@dealii.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From gdr at integrable-solutions dot net 2004-01-30 16:03 -------
Subject: Re: New: [3.3/3.4/3.5 regression] duplicate warning message for conversion
"bangerth at dealii dot org" <gcc-bugzilla@gcc.gnu.org> writes:
| This little gem
| -----------------
| int i = 1.;
| -----------------
| yields
| g/x> /home/bangerth/bin/gcc-3.4-pre/bin/c++ -c x.cc
| x.cc:1: warning: initialization to `int' from `double'
| x.cc:1: warning: argument to `int' from `double'
| which is not only duplicated, but also seems
| a) grammatically wrong in the first line (shouldn't it be
| "initialization OF 'int' from 'double'"?)
| b) nonsensical in the second line: it's not an argument TO
| a FUNCTION "int", it's the argument to the ASSIGNMENT
| to int
|
| Highly bogus...
Completely agreed. Even more so, I think the diagnostic should NOT be
emitted when the compiler does know for sure that the target can
accurately hold the initializer with no loss (which is the case here).
Will look into this after 3.3.3
-- Gaby
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13932