Topic: RTTI and private inheritance
Author: rmartin@rcmcon.com (Robert Martin)
Date: Fri, 17 Dec 1993 16:35:22 GMT Raw View
Cross Posted to comp.std.c++ from comp.lang.c++
An interesting question.
brad@amber.ssd.csd.harris.com (Brad Appleton) writes:
>I have a question as to how the proposed run-time type identification
>(RTTI) extensions to C++ behave with respect to private inheritance.
>Suppose I have the following:
> class MyStack : private LinkedList {
> // ...
> };
> // ...
> MyStack me_stack;
> MyStack * ptr2me_stack = &me_stack;
>Now suppose I use the RTTI extensions to try and convert a MyStack*
>into a LinkedList* ... will this succeed (since one is derived from
>the other) or will it fail because the inheritance is private?
>--
>______________________ "And miles to go before I sleep." _____________________
> Brad Appleton Harris Computer Systems, Fort Lauderdale, FL USA
> brad@ssd.csd.harris.com Disclaimer: I said it, not my employer!
--
Robert Martin | Design Consulting | Training courses offered:
Object Mentor Assoc.| rmartin@rcmcon.com | Object Oriented Analysis
2080 Cranbrook Rd. | Tel: (708) 918-1004 | Object Oriented Design
Green Oaks IL 60048 | Fax: (708) 918-1023 | C++
Author: satish@gandalf.mcs.clarkson.edu (Satish Thatte)
Date: Sat, 18 Dec 1993 01:50:40 GMT Raw View