From 280e4ce07d8b19ff4a5091b2d553da96ef98b489 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Mon, 9 Mar 2020 11:06:17 -0400 Subject: [PATCH] CAnimTreeAnimReaderContainer: std::move shared_ptr in constructor Provides the same behavior, but without a redundant atomic reference count increment and decrement. --- Runtime/Character/CAnimTreeAnimReaderContainer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Runtime/Character/CAnimTreeAnimReaderContainer.cpp b/Runtime/Character/CAnimTreeAnimReaderContainer.cpp index 16661690b..a7105b6ab 100644 --- a/Runtime/Character/CAnimTreeAnimReaderContainer.cpp +++ b/Runtime/Character/CAnimTreeAnimReaderContainer.cpp @@ -6,7 +6,7 @@ namespace urde { CAnimTreeAnimReaderContainer::CAnimTreeAnimReaderContainer(std::string_view name, std::shared_ptr reader, u32 dbIdx) -: CAnimTreeNode(name), x14_reader(reader), x1c_animDbIdx(dbIdx) {} +: CAnimTreeNode(name), x14_reader(std::move(reader)), x1c_animDbIdx(dbIdx) {} u32 CAnimTreeAnimReaderContainer::Depth() const { return 1; }