diff --git a/src/init.cpp b/src/init.cpp index a550006..6e565ae 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -12,7 +12,7 @@ namespace rng::init const std::function& apply_raw(std::string_view name, std::function fn) noexcept { if(!INIT_MAP) INIT_MAP = new ctor_map(); - + auto& map = *INIT_MAP; map[name] = std::move(fn); return map[name]; diff --git a/src/rng/sm64.cpp b/src/rng/sm64.cpp index 7600bab..5d4b493 100644 --- a/src/rng/sm64.cpp +++ b/src/rng/sm64.cpp @@ -3,4 +3,5 @@ #include +__attribute__((used)) RNGXX_APPLY_CTOR(rng, sm64, u64);