1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 22:27:35 +00:00

AK: Allow testing Empty instances for equality

This also makes it possible to compare `Variant<Empty, Ts...>`
objects if operator== exists for all Ts
This commit is contained in:
Shannon Booth 2023-07-27 22:14:56 +12:00 committed by Ali Mohammad Pur
parent 4f9f21e8fe
commit bf7af25a82
2 changed files with 30 additions and 0 deletions

View file

@ -217,6 +217,7 @@ using MergeAndDeduplicatePacks = InheritFromPacks<MakeIndexSequence<sizeof...(Ps
namespace AK {
struct Empty {
constexpr bool operator==(Empty const&) const = default;
};
template<typename T>