[Issue 17563] gc_inFinalizer should be public

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Wed Sep 13 02:44:29 UTC 2017


https://issues.dlang.org/show_bug.cgi?id=17563

safety0ff.bugz <safety0ff.bugz at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |safety0ff.bugz at gmail.com

--- Comment #3 from safety0ff.bugz <safety0ff.bugz at gmail.com> ---
An alternative solution worth considering is adding a parameter to destructors
(e.g. ~this(bool gcfinalizer=false)) and have the compiler handle
compatibility.

The advantage is that it is a better interface for future/alternate GC sweep
implementations. For example lazy/incremental sweep, concurrent sweep would
need to use thread local variables to manage the status.

--


More information about the Digitalmars-d-bugs mailing list