# Global Registration (a kind of pre-rfc)

**URL:** <https://internals.rust-lang.org/t/global-registration-a-kind-of-pre-rfc/20813>\
**Category:** language design\
**Created:** [May 13, 2024, 8:29am UTC](https://internals.rust-lang.org/t/global-registration-a-kind-of-pre-rfc/20813 "2024-05-13T08:29:21Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![Vorpal](https://avatars.discourse-cdn.com/v4/letter/v/aca169/32.png) [@Vorpal](https://internals.rust-lang.org/u/Vorpal)\
**Post date:** [May 13, 2024, 9:59am UTC](https://internals.rust-lang.org/t/global-registration-a-kind-of-pre-rfc/20813/4 "2024-05-13T09:59:33Z")

</div>

> [@josh](#):
>
> I personally suspect we'll end up going the fully static compile-time approach, with the assumption that dynamically loaded modules will need a different kind of dynamic registration mechanism. For instance, modules might need to provide some kind of metadata, or modules might have to make a call to register themselves.

How will this work in staticlibs integrated into C/C++ projects given that the linker is free to discard unreferenced objects / sections? And that it is a foot gun in C++ to do static constructor based registration already. How will this work across multiple rust staticlibs linked into the same C/C++ project?

---

_[View the full topic](https://internals.rust-lang.org/t/global-registration-a-kind-of-pre-rfc/20813)._
