diff --git a/src/core/tree/tree_branch.cpp b/src/core/tree/tree_branch.cpp index 8f61de31..69414dbf 100644 --- a/src/core/tree/tree_branch.cpp +++ b/src/core/tree/tree_branch.cpp @@ -58,7 +58,7 @@ bool Branch::addBranch(std::unique_ptr&& branch) return false; branch->setParent(this); - _branches.emplace(branchName, move(branch)); + _branches.emplace(branchName, std::move(branch)); for (const auto& id : _callbackTargetIds[Task::AddBranch]) _callbacks[id](*this, branchName); @@ -77,7 +77,7 @@ bool Branch::addLeaf(std::unique_ptr&& leaf) return false; leaf->setParent(this); - _leaves.emplace(leafName, move(leaf)); + _leaves.emplace(leafName, std::move(leaf)); for (const auto& id : _callbackTargetIds[Task::AddLeaf]) _callbacks[id](*this, leafName); @@ -240,7 +240,7 @@ bool Branch::renameBranch(const std::string& name, const std::string& newName) auto branchIt = _branches.find(name); branchIt->second->setName(newName); - _branches.emplace(newName, move(branchIt->second)); + _branches.emplace(newName, std::move(branchIt->second)); _branches.erase(name); return true; } @@ -253,7 +253,7 @@ bool Branch::renameLeaf(const std::string& name, const std::string& newName) auto leafIt = _leaves.find(name); leafIt->second->setName(newName); - _leaves.emplace(newName, move(leafIt->second)); + _leaves.emplace(newName, std::move(leafIt->second)); _leaves.erase(leafIt); return true; } diff --git a/src/graphics/renderer.h b/src/graphics/renderer.h index 0e182268..704bea0e 100644 --- a/src/graphics/renderer.h +++ b/src/graphics/renderer.h @@ -62,6 +62,8 @@ class Renderer static std::shared_ptr fromApi(Renderer::Api api); static std::shared_ptr create(std::optional api); + virtual ~Renderer() = default; + /** * Callback for GL errors and warnings * TODO: Make private once `Scene::getNewSharedWindow` is moved to the renderer. diff --git a/src/graphics/texture_image.h b/src/graphics/texture_image.h index 4f72b5a5..97307465 100644 --- a/src/graphics/texture_image.h +++ b/src/graphics/texture_image.h @@ -125,7 +125,7 @@ class Texture_Image : public Texture /** * Destructor */ - ~Texture_Image(); + virtual ~Texture_Image(); /** * Constructors/operators diff --git a/tests/unit_tests/core/tree.cpp b/tests/unit_tests/core/tree.cpp index d3b3a4fe..a14b3c5f 100644 --- a/tests/unit_tests/core/tree.cpp +++ b/tests/unit_tests/core/tree.cpp @@ -183,8 +183,8 @@ TEST_CASE("Testing adding and cutting existing branches and leaves") CHECK(leaf.get() != nullptr); oakSeeds = oak.getUpdateSeedList(); - maple.addBranchAt("/", move(branch)); - maple.addLeafAt("/", move(leaf)); + maple.addBranchAt("/", std::move(branch)); + maple.addLeafAt("/", std::move(leaf)); CHECK(maple == beech); CHECK(oak != beech);