From 91e5d4366b857f2441abe7c9a61b6154bd23ea3f Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Sat, 29 Oct 2022 21:46:28 +0300 Subject: [PATCH] Put Director's destructor in the .cpp file --- source/game/director.cpp | 4 ++++ source/game/director.h | 1 + 2 files changed, 5 insertions(+) diff --git a/source/game/director.cpp b/source/game/director.cpp index 96bd143..b06dff4 100644 --- a/source/game/director.cpp +++ b/source/game/director.cpp @@ -12,6 +12,10 @@ Director::Director(DataFile::Collection &r): event_source(event_bus) { } +// Hide ~unique_ptr from the header +Director::~Director() +{ } + Stage &Director::create_stage() { stages.emplace_back(std::make_unique(std::ref(resources))); diff --git a/source/game/director.h b/source/game/director.h index 05be9f7..de19185 100644 --- a/source/game/director.h +++ b/source/game/director.h @@ -33,6 +33,7 @@ private: public: Director(DataFile::Collection &); + ~Director(); DataFile::Collection &get_resources() const { return resources; } EventBus &get_event_bus() { return event_bus; } -- 2.43.0