Boost logo

Boost :

From: Larry Evans (jcampbell3_at_[hidden])
Date: 2002-10-04 16:52:23


David B. Held wrote:

>"Schoenborn, Oliver" <Oliver.Schoenborn_at_[hidden]> wrote in message
>
>
[snip]

>
>
>Deriving from ptr<T const> is a weird beast. For instance, if you declare
>T* p_; in ptr<T const>, for some reason, it is not visible in ptr<T>, even
>
I'm totally surprised!

>if
>it is protected or public, with public inheritance! I don't get it, but
>that seems
>to be the way it is. Furthermore, methods of ptr<T const> seem to *not*
>get inherited by ptr<T>. It seems that the only thing that *does* get
>inherited
>is the type itself. Explain that! If you don't believe me, try this code
>under
>
>
[snip code]

I tried it with gcc version 2.96 and it compiles without problem.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk