[C++-sig] Re: operator ->, cast operator
Leonard "paniq" Ritter
paniq at paniq.org
Sun Mar 13 00:55:22 CET 2005
>You also need
>
>namespace Mu
>{
> template <class T>
> T* get_pointer(Ptr<T> const& p)
> {
> return p.get(); // or something
> }
>}
>
>
>
in my case GetObject() which needed to be const. assuming the problem
was that i have not defined const cast operators i declared various
flavors of cast operators in Ptr<>, but without luck. only adding
get_pointer would make it work.
is the requirement of get_pointer somewhere mentioned in the
documentation? i was unable to find it.
More information about the Cplusplus-sig
mailing list