(root)/
gcc-13.2.0/
gcc/
testsuite/
g++.dg/
cpp2a/
spaceship-rewrite4.C
// { dg-do compile { target c++11 } }

struct iterator;
struct const_iterator {
  const_iterator(const iterator&);
  bool operator==(const const_iterator &ci) const = delete;
};
struct iterator {
  bool operator==(const const_iterator &ci) const {
    return ci == *this;		// { dg-error "deleted" "" { target c++17_down } }
  }				// { dg-warning "reversed" "" { target c++20 } .-1 }
};