Clean-up build warnings

RESOLVED INVALID

Status

Core Graveyard
Tracking
P3
normal
RESOLVED INVALID
19 years ago
2 years ago

People

(Reporter: Steve Lamm, Assigned: Steve Lamm)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(URL)

(Assignee)

Description

19 years ago
Please cleanup your build warnings (url is in the URL field above). Driving for
beta is a great time to bring down the warning noise.

http://tinderbox.mozilla.org/SeaMonkey/warnings.html#michaelp

Now you have a bug so you can check in your fixes. =)
(Assignee)

Comment 1

19 years ago
Check out the following link for more information on the "...was hidden by..."
warnings that you have.

http://www.cerfnet.com/~mpcline/On-Line-C++-FAQs/strange-inheritance.html#[23.3]
(Be sure to get the last "]" bugzilla seems to cut it off.)

Also, here are some comments from scc that pierre added to bug #15636,

Yup.  It's a valid warning.  A name declared in a derived class hides
|all| previous declarations of the same name, regardless of signature.
  This is why over-riding and overloading don't mix.  Even if all the
|f|s in your sample were virtual, |Derived::f(int, int)| would hide
|Base::f(int)|.

This is to prevent an accident where somebody adds a new method to a
base class where, coincidentally, some derived class has a function
with the same name.  Without this rule, the entire meaning of the
program could be subtly changed.  With this rule, the meaning is the
same, and a warning is issued.

To get around it, bring all the names into scope with |using|, e.g.,

   class Derived : public Base {
     using Base::f;
       // bring all |f|s into scope, so I don't hide them

     int f(int, int);
       // now override the one I care about
   }

If |using| is not allowed, then you have to override all of them.
(Assignee)

Updated

19 years ago
QA Contact: leger → slamm

Comment 2

19 years ago
reassigning to slamm. I just noticed that this was owned by
michaelp@netscape.com. This is an invalid email address. I'll
let you figure out what to do with this bug long term.
Assignee: michaelp → slamm
(Assignee)

Comment 3

18 years ago
I will file new bugs on people as needed.
Status: NEW → RESOLVED
Last Resolved: 18 years ago
Resolution: --- → INVALID
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.