1 // 13.1: ...cannot be overloaded if any of them, but not all, have a 2 // ref-qualifier. 3 4 // { dg-require-effective-target c++11 } 5 6 class Y { 7 void h() &; 8 void h() const &; // OK 9 void h() &&; // OK, all declarations have a ref-qualifier 10 void i() &; // { dg-message "" } 11 void i() const; // { dg-error "" } prior declaration of i 12 // has a ref-qualifier 13 }; 14