inherited virtual function is hidden

VERIFIED WONTFIX

Status

()

Core
XPCOM
P2
normal
VERIFIED WONTFIX
19 years ago
19 years ago

People

(Reporter: Brade, Assigned: Scott Collins)

Tracking

Trunk
PowerPC
Mac System 8.5
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

19 years ago
[Please reassign or change component as appropriate]

From Macintosh compiler (nsRangeList.cpp in layout.mcp):

Warning : 'nsDerivedSafe<nsISupportsArray>::operator=(const nsDerivedSafe<
nsISupportsArray> &)' hides inherited virtual function
'nsISupportsArray::operator=(const nsISupportsArray &)'
(instantiating: 'nsDerivedSafe<nsISupportsArray>')
nsCOMPtr.h line 367   };

Updated

19 years ago
Component: XP-COM → XPCOM
Product: Mozilla → NGLayout

Comment 1

19 years ago
Moving bug fomr XP-COM to XPCOM.  Cleaning up Bugzilla.  XP-COM will be removed.
(Assignee)

Updated

19 years ago
Status: NEW → RESOLVED
Last Resolved: 19 years ago
Resolution: --- → WONTFIX
(Assignee)

Comment 2

19 years ago
Right.  I know this sounds strange, but this is what I intended to happen.  |
nsDerivedSafe| hides inherited |operator=| because you couldn't possibly get the
right one.  |nsDerivedSafe| makes |operator=| private so you can't call it and
accidentally slice in the following circumstance

  *myCOMPtr = *someOtherPointer;

I wish I could supress the warning, but I can't.  Sorry.

Updated

19 years ago
Status: RESOLVED → VERIFIED

Comment 3

19 years ago
Marking Verified/Won't Fix.
You need to log in before you can comment on or make changes to this bug.