From decd75ec46df2e3a4f0450ce652af01501497544 Mon Sep 17 00:00:00 2001 From: Redstone1024 <2824517378@qq.com> Date: Fri, 1 Nov 2024 23:20:55 +0800 Subject: [PATCH] fix(templates): fix TReferenceWrapper::operator= no return value --- Redcraft.Utility/Source/Public/Templates/ReferenceWrapper.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Redcraft.Utility/Source/Public/Templates/ReferenceWrapper.h b/Redcraft.Utility/Source/Public/Templates/ReferenceWrapper.h index 404fcbf..73a8f1c 100644 --- a/Redcraft.Utility/Source/Public/Templates/ReferenceWrapper.h +++ b/Redcraft.Utility/Source/Public/Templates/ReferenceWrapper.h @@ -39,14 +39,16 @@ public: : Pointer(InValue.Pointer) { } - /** Assigns by copying the content of other. */ + /** Assigns by copying the content of others. */ FORCEINLINE constexpr TReferenceWrapper& operator=(const TReferenceWrapper&) = default; - /** Assigns by copying the content of other. */ + /** Assigns by copying the content of others. */ template requires (CConvertibleTo) FORCEINLINE constexpr TReferenceWrapper& operator=(const TReferenceWrapper& InValue) { Pointer = InValue.Pointer; + + return *this; } /** @return The stored reference. */