View source code
Display the source code in core/gc/registry.d from which this
page was generated on github.
Report a bug
If you spot a problem with this page, click here to create a
Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page.
Requires a signed-in GitHub account. This works well for small changes.
If you'd like to make larger changes you may want to consider using
local clone.
Function core.gc.registry.registerGCFactory
Register a GC factory under the given name
. This function must be called
from a C constructor before druntime is initialized.
void registerGCFactory
(
string name,
core .gc .gcinterface .GC function() factory
) nothrow @nogc;
To use the registered GC, it's name must be specified gcopt runtime option, e.g. by passing , --DRT-gcopt=gc:my_gc_name as application argument.
Parameters
Name | Description |
---|---|
name | name of the GC implementation; should be unique |
factory | function to instantiate the implementation |
Note
The registry does not perform synchronization, as registration is assumed to be executed serially, as is the case for C constructors.
See Also
Authors
Martin Nowak
License
Copyright © 1999-2024 by the D Language Foundation | Page generated by ddox.