From 3de2a8ba2c4bb172316223149616903b440aa38b Mon Sep 17 00:00:00 2001 From: Morph <39850852+Morph1984@users.noreply.github.com> Date: Thu, 14 Oct 2021 14:21:15 -0400 Subject: core: Remove static system instance --- src/core/core.cpp | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'src/core/core.cpp') diff --git a/src/core/core.cpp b/src/core/core.cpp index bb268a3197..ae1d56b27c 100644 --- a/src/core/core.cpp +++ b/src/core/core.cpp @@ -428,21 +428,8 @@ struct System::Impl { }; System::System() : impl{std::make_unique(*this)} {} -System::~System() = default; - -System& System::GetInstance() { - if (!s_instance) { - throw std::runtime_error("Using System instance before its initialization"); - } - return *s_instance; -} -void System::InitializeGlobalInstance() { - if (s_instance) { - throw std::runtime_error("Reinitializing Global System instance."); - } - s_instance = std::unique_ptr(new System); -} +System::~System() = default; CpuManager& System::GetCpuManager() { return impl->cpu_manager; -- cgit v1.2.3