This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: c++/8205: using declaration & mulitiple inheritance
- From: bangerth at dealii dot org
- To: chicares at mindspring dot com, gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, hou_zhenyu at hotmail dot com, nobody at gcc dot gnu dot org
- Date: 4 Nov 2002 22:46:16 -0000
- Subject: Re: c++/8205: using declaration & mulitiple inheritance
- Reply-to: bangerth at dealii dot org, chicares at mindspring dot com, gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, hou_zhenyu at hotmail dot com, nobody at gcc dot gnu dot org, gcc-gnats at gcc dot gnu dot org
Old Synopsis: using declaration doesn't work while mulitiple inheritance was used.
New Synopsis: using declaration & mulitiple inheritance
State-Changed-From-To: open->analyzed
State-Changed-By: bangerth
State-Changed-When: Mon Nov 4 14:46:16 2002
State-Changed-Why:
Right, this is a regression in 3.2, as it compiled cleanly
in 2.95.I thus set the priority to "high" and let others
decide what to do with it.
However, it turns out that this is fixed on the mainline
again (or the problem was never introduced there). For
reference, I append the code in question below.
Regards
Wolfgang
-------------------------
class A { public: int i; };
class B {};
class E : A, B { public: using A::i; };
int main() {
E e;
e.i; // "`A' is an inaccessible base of `E'"
}
----------------------------------
tmp/g> /home/bangerth/bin/gcc-3.2.1-pre/bin/c++ -c x.cc
x.cc: In function `int main()':
x.cc:7: `A' is an inaccessible base of `E'
tmp/g> /home/bangerth/bin/gcc-3.3x-pre/bin/c++ -c x.cc
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8205