This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/20637] [3.3/3.4/4.0/4.1 regression] Confusing message with different using declarations
- 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: 26 Mar 2005 04:28:28 -0000
- Subject: [Bug c++/20637] [3.3/3.4/4.0/4.1 regression] Confusing message with different using declarations
- References: <20050325162709.20637.bangerth@dealii.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From gdr at integrable-solutions dot net 2005-03-26 04:28 -------
Subject: Re: New: [3.3/3.4/4.0/4.1 regression] Confusing message with different using declarations
"bangerth at dealii dot org" <gcc-bugzilla@gcc.gnu.org> writes:
| This was hard to find. Consider this snippet:
| ------------------
| struct B {
| void f();
| };
|
| struct D : B {
| using B::f;
| B::f;
| };
| ------------------
| Note that D contains old- and new-style using declarations. In my case, they
| were several hundred lines apart in D, so it wasn't quite so obvious. What
| I get is this:
|
| g/x> /home/bangerth/bin/gcc-4*/bin/c++ -c a.cc
| a.cc:2: error: ?void B::f()? and ?void B::f()? cannot be overloaded
|
| Note that it doesn't show where the attempt to overload happens, it only shows
| the original place. That's bad diagnostics.
Agreed. But, I don't think that will be fixed in 3.3.x
-- Gaby
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20637