Re: [Vala] reference management.



On Die, 2007-03-20 at 16:29 -0300, Alexandre Moreira wrote:
By the way, how are GIOChannels handled by assisted memory management
? I have a class that I intend to port from C to Vala and I deal with
a few Channels in it.

GIOChannel supports reference counting, so that will work the same as
with GObjects. It's possible that you'll get some warnings as the
compiler doesn't know yet that GIOChannel supports reference counting
but it should work fine.

PS: Please, if you ever decide on going to a full garbage collector,
please allow me and other memory leakers to handle their own
references and frees and deletes and whatever... even if you quit this
"auto-dereference" stuff to substitute it for the garbage collector,
being able to fall back to full-manual memory management would keep me
using Vala happily :)

We're not planning to remove the current memory management support, the
full garbage collector will be optional.

Jürg




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