int test4_1235() { A a; const A ca = a; volatile A va; const volatile A cva = a; sink_4_1235(cva); // { dg-error "no match" } sink_4_1235(v_source()); // { dg-error "no match" } sink_4_1235(cv_source()); // { dg-error "no match" } return 0; }
int test4_1235() { A a; const A ca = a; // { dg-error "lvalue" } volatile A va; const volatile A cva = a; // { dg-error "lvalue" } sink_4_1235(cva); // { dg-error "no match" } // { dg-message "candidate" "candidate note" { target *-*-* } 62 } sink_4_1235(v_source()); // { dg-error "no match" } // { dg-message "candidate" "candidate note" { target *-*-* } 64 } sink_4_1235(cv_source()); // { dg-error "no match" } // { dg-message "candidate" "candidate note" { target *-*-* } 66 } return 0; }