Re: Glib::Refptr and circular references
- From: "Matt Hoosier" <mwhoosier gmail com>
- To: "Nickolai Dobrynin" <ndobrynin gmail com>, gtkmm-list gnome org
- Subject: Re: Glib::Refptr and circular references
- Date: Thu, 13 Jul 2006 10:12:30 -0500
Thanks for the link.
On 7/12/06, Nickolai Dobrynin <ndobrynin gmail com> wrote:
Matt,
The following should be helpful:
http://developer.gnome.org/doc/API/2.0/gobject/gobject-memory.html
Regards,
Nickolai
On 7/10/06, Matt Hoosier <mwhoosier gmail com> wrote:
>
Hi all,
The occasion of using a Glib::Refptr from gtkmm's API recently reminds
me about an old question. I've been wondering for some time now how
the GObject-using world deals with the problem of circular references.
The classic example would be a node of a (circular) linked list which
is also pointed to by application code. Once the app drops its ref to
the node, at least one more reference (the internal back-edge from the
linked list) still exists.
Now, I know that Glib has a special-built linked list data structure
to prevent this elementary example, but it's fairly easy to imagine
scenarios where this happens unintentionally. Is this simply a known
limitation, accompanied by the stern warning to be careful in one's
design not to introduce circular references?
Apologies if there's already a manifesto about this somewhere in the
Glib tutorial, but I didn't find it.
--Matt
_______________________________________________
gtkmm-list mailing list
gtkmm-list gnome org
http://mail.gnome.org/mailman/listinfo/gtkmm-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]