This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: c++/9558: subclass cannot find parent members without explicit"this->" in some cases
- From: "Ryan C. Gordon" <ryan at epicgames dot com>
- To: bangerth at dealii dot org, gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, nobody at gcc dot gnu dot org
- Date: Mon, 03 Feb 2003 19:04:22 -0500
- Subject: Re: c++/9558: subclass cannot find parent members without explicit"this->" in some cases
- Organization: Epic Games
- References: <20030203234509.31119.qmail@sources.redhat.com>
bangerth@dealii.org wrote:
Synopsis: subclass cannot find parent members without explicit "this->" in some cases
State-Changed-From-To: open->closed
State-Changed-By: bangerth
State-Changed-When: Mon Feb 3 23:45:09 2003
State-Changed-Why:
That's how C++ works -- it's a feature, not a bug, and
it's called two-stage (or dependent) name lookup.
We really need to get an entry into the non-bugs page about
this, we are getting far too many reports about this...
W.
If that's how C++ works in the official spec, it's not how it works in
real life.
I've got half a million lines of code in Unreal Tournament 2003 that
this "feature" breaks, which compile fine on everything from CodeWarrior
to Intel's compiler to Visual C to GCC 2.95.3, 3.1, and 3.2. I can list
at least five other games I've worked on that this breaks. I do not
control or write this code, I just port it.
Surely there's got to be some consideration for backwards compatibility,
if not real world issues?
--ryan.