[Oberon] Fw: FPGA - Bitmaps.Mod
andreas_pirklbauer at yahoo.com
Fri Apr 7 17:41:33 CEST 2017
To be precise:
If you don't make dynamically allocated objects reachable via at least one global pointer variable, they simply won't be marked during the mark phase of the garbage collector, which means that they *will* be collected during the subsequent scan phase. That's the whole point of garbage collection...
From: Andreas Pirklbauer <andreas_pirklbauer at yahoo.com>
To: ETH Oberon and Related Systems <oberon at lists.inf.ethz.ch>
Cc: Andreas Pirklbauer <andreas_pirklbauer at yahoo.com>
Sent: Friday, April 7, 2017 5:35 PM
Subject: [Oberon] Fw: FPGA - Bitmaps.Mod
4. If you want your objects to be automatically collected by the Oberon garbage collector, you must make it globally reachable via a global pointer. Then they will appear in mod.ptr in the module block which are used as roots for the garbage collector. (Oberon uses all named pointer variables in existence as roots for the mark phase of the garbage collector. See Oberon.GC for the details. It simply calls Kernel.Mark(mod.ptr) for each loaded module mod.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Oberon