2011-11-24 10:05, Murray Cumming skrev:
On Thu, 2011-11-24 at 10:01 +0100, Kjell Ahlstedt wrote:#define G_PRIVATE_INIT(notify) { NULL, (notify), { NULL, NULL } } can be used for initialization, but it can't be used for assignment. This version builds: template<class T> inline Private<T>::Private(typename Private<T>::DestructorFunc destructor_func) { GPrivate temp = G_PRIVATE_INIT(destructor_func); gobject_ = temp; } I similar trick is used in glib/glib/deprecated/gthread-deprecated.c, function g_private_new().Thanks. Please commit that, with an explanatory comment. A const before GPrivate might be nice if that works.
Done. With a comment and a const. http://git.gnome.org/browse/glibmm/commit/?id=2269b8027962af18bdd7260329eda3e5427eea43 _______________________________________________ gtkmm-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/gtkmm-list
