aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp2a/spaceship-eq5.C
blob: 429d31a2212406f65756d3e951a833cf72e7ac70 (plain)
1
2
3
4
5
6
7
8
9
10
// { dg-do compile { target c++20 } }

struct A {
  int &r;			// { dg-message "reference" }
  bool operator==(const A&) const = default; // { dg-message "deleted" }
};

int i;
A a { i };
bool b = a == a;		// { dg-error "deleted" }