[D-runtime] druntime ModuleInfo discovery without bracketing segments

David Nadlinger code at klickverbot.at
Sun Aug 25 15:38:06 PDT 2013


On Mon, Jun 17, 2013 at 2:52 PM, Johannes Pfau
<johannespfau at googlemail.com> wrote:
> Of course then you couldn't access all ModuleInfos... sorry for the noise.
>
> It could actually be implemented similar to crtbeginS.o and crtendS.o which
> are used to run the global c constructors though, but then it's platform
> specific again.

Mhm, at least on Linux, crtbegin.o/crtend.o are special-cased in the
linker script so that their contents end up at the appropriate place
in the executable (i.e. bracketing the .cdots/.dtors.

David


More information about the D-runtime mailing list