diff --git a/libsrc/core/archive.cpp b/libsrc/core/archive.cpp index 448b8f47..7937e64d 100644 --- a/libsrc/core/archive.cpp +++ b/libsrc/core/archive.cpp @@ -22,11 +22,6 @@ namespace ngcore std::make_unique>(); (*type_register)[classname] = info; } - void Archive :: RemoveArchiveRegister(const std::string& classname) - { - if(IsRegistered(classname)) - type_register->erase(classname); - } bool Archive :: IsRegistered(const std::string& classname) { if(type_register == nullptr) type_register = diff --git a/libsrc/core/archive.hpp b/libsrc/core/archive.hpp index bddd2533..cbe17e27 100644 --- a/libsrc/core/archive.hpp +++ b/libsrc/core/archive.hpp @@ -646,7 +646,6 @@ namespace ngcore // Set ClassArchiveInfo for Demangled typeid, this is done by creating an instance of // RegisterClassForArchive static void SetArchiveRegister(const std::string& classname, const detail::ClassArchiveInfo& info); - static void RemoveArchiveRegister(const std::string& classname); static bool IsRegistered(const std::string& classname); // Helper class for up-/downcasting @@ -713,12 +712,6 @@ namespace ngcore { return typeid(T) == ti ? p : Archive::Caster::tryDowncast(ti, p); }; Archive::SetArchiveRegister(std::string(Demangle(typeid(T).name())),info); } - ~RegisterClassForArchive() - { - Archive::RemoveArchiveRegister(std::string(Demangle(typeid(T).name()))); - } - - }; // BinaryOutArchive ======================================================================