[osg-submissions] osg::Object::clone

Daniel Trstenjak Daniel.Trstenjak at science-computing.de
Fri Jun 6 06:32:37 PDT 2008


Hi Stephan,

On Fri, Jun 06, 2008 at 03:21:06PM +0200, Stephan Maximilian Huber wrote:
> To my knowledge, the code will fail because the c++compiler will call 
> osg::Object::clone and not osg::Transform::clone because the function 
> signatures differ (they return different types of objects).

The return value isn't part of the signature of a method. You can't
overload a method by only changing the return value.


Greetings,
Daniel

-- 
                                                                                                                                           
 Daniel Trstenjak                                 Tel. +49 (0)7071-9457-264
 science + computing ag                           FAX  +49 (0)7071-9457-511
 Hagellocher Weg 73           mailto: Daniel.Trstenjak at science-computing.de
 D-72070 Tübingen             WWW   : http://www.science-computing.de/                                                                      
-- 
Vorstand/Board of Management:
Dr. Bernd Finkbeiner, Dr. Florian Geyer,
Dr. Roland Niemeier, Dr. Arno Steitz, Dr. Ingrid Zech
Vorsitzender des Aufsichtsrats/
Chairman of the Supervisory Board:
Prof. Dr. Hanns Ruder
Sitz/Registered Office: Tuebingen
Registergericht/Registration Court: Stuttgart
Registernummer/Commercial Register No.: HRB 382196 




More information about the osg-submissions mailing list