[Rd] destructor for S4 class objects in analogy to C++
armstrong.whit at gmail.com
Tue Jul 21 19:22:45 CEST 2009
if you are using external pointers, then R allows you to set a
finalizer function to be called on the pointer.
see examples in RODBC package.
and here too:
see the "connFinalizer" function
On Tue, Jul 21, 2009 at 1:00 PM, David
Scherrer<dasmailinglists at gmail.com> wrote:
> Hi all,
> I'm wondering if there is a way to define a destructor function (to free
> memory) for S4 class objects in analogy to C++?
> rm() combined with gc() does not seem to be a good idea (Chambers, 2008).
> So could it be done on the C/C++ level or is it even already available in
> the "internals"?
> Many thanks,
> [[alternative HTML version deleted]]
> R-devel at r-project.org mailing list
More information about the R-devel