Re: Pointer casting related question



use Glib::RefPtr<destination_type>::cast_dynamic(source_refptr)

or cast_static if you can guarantee that the cast is valid, does not require adjustment for multiple/virtual inheritance, and don't want the (probably insignificant) overhead of a checked cast.

see:
https://developer.gnome.org/glibmm/stable/classGlib_1_1RefPtr.html#afba688c406f0c3d1239c6b7c3716c1de
https://mail.gnome.org/archives/gtkmm-list/2010-August/msg00051.html




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]