libstdc++: Add missing equality comparison in new tests [PR117921]

These new tests fail in Debug Mode because the allocator types aren't
equality comparable.

libstdc++-v3/ChangeLog:

	PR libstdc++/117921
	* testsuite/23_containers/set/modifiers/swap/adl.cc: Add
	equality comparison for Allocator.
	* testsuite/23_containers/unordered_set/modifiers/swap-2.cc:
	Likewise.
This commit is contained in:
Jonathan Wakely 2024-12-09 09:36:15 +00:00 committed by Jonathan Wakely
parent 0b79d8b98e
commit 5cdd78b397
No known key found for this signature in database
2 changed files with 2 additions and 0 deletions

View file

@ -36,6 +36,7 @@ namespace adl
using propagate_on_container_swap = std::true_type;
friend void swap(Allocator&, Allocator&) { swapped = true; }
friend bool operator==(Allocator, Allocator) { return true; }
};
}

View file

@ -43,6 +43,7 @@ namespace adl
using propagate_on_container_swap = std::true_type;
friend void swap(Allocator&, Allocator&) { swapped = true; }
friend bool operator==(Allocator, Allocator) { return true; }
};
}