Closed
Bug 15576
Opened 27 years ago
Closed 27 years ago
Clean-up build warnings
Categories
(Core Graveyard :: Tracking, defect, P3)
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: slamm, Assigned: dcone)
References
()
Details
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#dcone
Now you have a bug so you can check in your fixes. =)
| Reporter | ||
Comment 1•27 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•27 years ago
|
Status: NEW → ASSIGNED
| Assignee | ||
Updated•27 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 27 years ago
Resolution: --- → FIXED
| Reporter | ||
Comment 2•27 years ago
|
||
A few more warnings popup up. These new ones look easy.
| Assignee | ||
Comment 3•27 years ago
|
||
I fixed these, waiting for the tree to open....
| Reporter | ||
Updated•27 years ago
|
Status: REOPENED → RESOLVED
Closed: 27 years ago → 27 years ago
| Reporter | ||
Comment 4•27 years ago
|
||
I see you checked in fixes for the new warnings.
Marking fixed/verified.
| Reporter | ||
Updated•27 years ago
|
Status: RESOLVED → VERIFIED
Updated•10 years ago
|
Product: Core → Core Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•