core :: Finalizable :: finalize
self
before the memory holding self
is freedThis method is invoked by the GC during a garbage collection when self
is no longer referenced. It can also be called by the user. Its implementation
must be planned accordingly and ensure that it may be invoked more than once.
The object are not finialized in a topological order, it is safe for this method to use attributes of this instances, unless theses attributes are finalizable as well because they may have been finalized already.
# Liberate any resources held by `self` before the memory holding `self` is freed
#
# This method is invoked by the GC during a garbage collection when `self`
# is no longer referenced. It can also be called by the user. Its implementation
# must be planned accordingly and ensure that it may be invoked more than once.
#
# The object are not finialized in a topological order, it is safe for this method
# to use attributes of this instances, unless theses attributes are finalizable as well
# because they may have been finalized already.
fun finalize do end
lib/core/gc.nit:28,2--37,20