Re: Delphi32 & Delphi.NET Should Both Have *Optional* Garbage Collection



Bryce,
I sorta thought the DotNet version already was an optional garbage collector, if you used VCL.NET I mean. With VCL.NET, can't you either free/dispose everything yourself via the "normal" way, or let the garbage collector get it when it wants?

-BKN

Hi Bryce,
it's not free-ing, it's disposing. And actually, you have to, it's not optional as there are unmanaged resources involved for which GC has no clue what to do with.
If you know, that a specific VCL.Net does not use unmaged stuff, you don't need to dispose it. Even if you did, it wouldn't "free" the object. ;-)
Please correct me, if this was wrong, I'm not that familiar with VCL.Net...
.




Relevant Pages

  • Re: how to remove a programmatically created DateTimePicker
    ... Apparently my laptop got a life ... "The garbage collector runs in time intervals, ... unmanaged resources, that has not much to do with disposing an object, ... disposing of an object is done by the GC. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: how to remove a programmatically created DateTimePicker
    ... "The garbage collector runs in time intervals, ... unmanaged resources, that has not much to do with disposing an object, ... disposing of an object is done by the GC. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: JuggleSim - a new juggling simulator
    ... It is probably something like not disposing of an image correctly, ... showing 0-2% ... Does it climb up to 1.3GB and then drop down and repeat that when you run ... I think what it is is that the garbage collector for some reason doesn't ...
    (rec.juggling)
  • Re: Lisp in hardware
    ... Alexander Burger writes: ... so that for example the garbage collector can do special things ... > with it (like not always disposing of it, ...
    (comp.lang.lisp)
  • Re: disposing the database object??
    ... The OP did not show the class structure there, ... garbage collector will handle disposing that object when he exits the ...
    (microsoft.public.dotnet.framework.adonet)