// Copyright Epic Games, Inc. All Rights Reserved. #pragma once #include "Misc/TVariant.h" #include "Templates/Decay.h" namespace UE::Mutable::Private { // TVariant currently does not support this operator. Once supported remove it. template bool operator==(const TVariant& ValueA, const TVariant& ValueB) { const int32 IndexA = ValueA.GetIndex(); const int32 IndexB = ValueB.GetIndex(); if (IndexA != IndexB) { return false; } return Visit([&ValueB](const auto& StoredValueA) { using Type = typename TDecay::Type; return StoredValueA == ValueB.template Get(); }, ValueA); } }