[osg-submissions] Fix "hidden virtual" warnings introduced since 2.2.0

Andy Skinner Andy.Skinner at mathworks.com
Sat May 24 06:46:21 PDT 2008


We've been around on this one, too.  The warning is correct, in that virtual methods are hidden.  It isn't a bug in this case because of the way the visitor is used.  But because the warning reports something that could be a problem, I hate to tell it to never complain about it.  I wish we could put in the "using" statements, too.

andy

-----Original Message-----
From: osg-submissions-bounces at lists.openscenegraph.org [mailto:osg-submissions-bounces at lists.openscenegraph.org] On Behalf Of Robert Osfield
Sent: Saturday, May 24, 2008 5:22 AM
To: OpenSceneGraph Submissions
Subject: Re: [osg-submissions] Fix "hidden virtual" warnings introduced since 2.2.0

Hi Tim,

On Sat, May 24, 2008 at 10:08 AM, Tim Moore <timoore at redhat.com> wrote:
> I understand that this "bug" doesn't affect the operation of
> NodeVisitor,

This isn't a "bug", its a bogus warning, the bug is in the compiler
producing appropriate warnings that lead enigeers to do stupid stuff.

> but isn't it sufficient to say "using NodeVisitor::apply;"
> in the definition of the derived classes in order to make the warning
> go away?

Well if the bug is in the compiler then you should be fixing it in the
build system not the source.

Robert.
_______________________________________________
osg-submissions mailing list
osg-submissions at lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org


More information about the osg-submissions mailing list