blob: c6acb7b5a80236bd6ed10c3e26a6fc74b53dd672 [file] [log] [blame]
// PR c++/92774
// { dg-do compile { target c++20 } }
#include <compare>
template<typename T>
struct X { };
template<typename T>
bool operator==(const X<T>&, const X<T>&) { return true; }
template<typename T>
bool operator<(const X<T>&, const X<T>&) { return true; }
struct Y
{
int a;
X<int> c; // { dg-error "no match" }
auto operator <=>(Y const&) const = default;
};
void f()
{
auto x = Y() < Y(); // { dg-error "deleted" }
}