Copy link
@MartinNowak

MartinNowak Dec 2, 2013

Contributor

You should actually be able to just emit one function and a reference into .ctors/.dtors each.
The _d_dso_registry implementation can tag the shared library using the dsoSlot to detect whether it should run ctor or dtor.
Also you could save the dsoInitiaized guard.