diff --git a/Userland/DevTools/UserspaceEmulator/ValueWithShadow.h b/Userland/DevTools/UserspaceEmulator/ValueWithShadow.h index db23c2597b..ba1a0c2795 100644 --- a/Userland/DevTools/UserspaceEmulator/ValueWithShadow.h +++ b/Userland/DevTools/UserspaceEmulator/ValueWithShadow.h @@ -100,7 +100,7 @@ public: return (m_shadow & 0x01) != 0x01; } - void operator=(const ValueWithShadow&); + ValueAndShadowReference& operator=(const ValueWithShadow&); T& value() { return m_value; } T& shadow() { return m_shadow; } @@ -162,10 +162,11 @@ inline ValueWithShadow::ValueWithShadow(const ValueAndShadowReference& oth } template -inline void ValueAndShadowReference::operator=(const ValueWithShadow& other) +inline ValueAndShadowReference& ValueAndShadowReference::operator=(const ValueWithShadow& other) { m_value = other.value(); m_shadow = other.shadow(); + return *this; } }